Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Dec 9, 2025

Issue requested implementation of Dmod_Stdin_SetFlags and Dmod_Stdin_GetFlags SAL functions added to dmod.

Status

Functions already implemented in PR #49. No changes required.

Implementation Details

Both functions exist in src/dmlog.c:

  • Dmod_Stdin_GetFlags() - Converts internal dmlog flags to DMOD_STDIN_FLAG format
  • Dmod_Stdin_SetFlags(uint32_t) - Converts DMOD_STDIN_FLAG format to internal dmlog flags
// Constants from dmod SAL (dmod_sal.h)
#define DMOD_STDIN_FLAG_ECHO        (1 << 0)  // Enable echo
#define DMOD_STDIN_FLAG_CANONICAL   (1 << 1)  // Line-buffered mode

// Usage example
uint32_t flags = Dmod_Stdin_GetFlags();
Dmod_Stdin_SetFlags(DMOD_STDIN_FLAG_CANONICAL);  // No echo, canonical mode

Test Coverage

Comprehensive tests in tests/test_dmod_input_api.c verify flag manipulation and effect on input behavior. All 50 tests passing.

Original prompt

This section details on the original issue you should resolve

<issue_title>Dodać Dmod_Stdin_SetFlags i Dmod_Stdin_GetFlags</issue_title>
<issue_description>W dmod zostaly dodane nowe funkcje SAL, ktore musimy zaimplementowac (jesli jeszcze ich nie ma)</issue_description>

Comments on the Issue (you are @copilot in this section)


✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.

Copilot AI changed the title [WIP] Add Dmod_Stdin_SetFlags and Dmod_Stdin_GetFlags functions Verify Dmod_Stdin_SetFlags and Dmod_Stdin_GetFlags implementation is complete Dec 9, 2025
Copilot AI requested a review from JohnAmadis December 9, 2025 11:58
@JohnAmadis JohnAmadis closed this Dec 9, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Dodać Dmod_Stdin_SetFlags i Dmod_Stdin_GetFlags

2 participants