1
0
mirror of https://github.com/vlang/v.git synced 2023-08-10 21:13:21 +03:00
Commit Graph

4 Commits

Author SHA1 Message Date
Delyan Angelov
32114a679a
os,term.termios: add termios.set_state/2, state.disable_echo/0, use them in os.input_password, to fix v -os wasm32_emscripten examples/2048/ 2023-07-31 10:28:45 +03:00
Thomas Mangin
580d9cedc7
termios: new termios module (#17792)
* termio: new termio module

move the tcgetattr and tcsetattr functions in a new termio module.
The code needed refactoring as different OS have different fields
size, position and number for the C.termios structure, which
could not be correctly expressed consitently otherwise.

It has the positive side effect to reduce the number of unsafe calls.
New testing code was also added for the readline module as it is
relying of the feature.

* apply 2023 copyright to the new files too
2023-03-30 08:58:52 +03:00
Delyan Angelov
b13f7118ab
os,term: fix C.tcsetattr declaration (add missing int return type) 2023-02-13 15:16:23 +02:00
Subhomoy Haldar
3b42f18dee
os: add input_password(prompt) and unit tests (#15507) 2022-08-23 18:17:38 +03:00