On 9/7/22 16:24, Synopsis wrote:
> a- What is the difference with this syntax with the exclamation mark?
> ```readf!"%s\n"(f1.num);```
That's the templated version, which is safer because it checks at
compile time (important distinction) that the arguments and the format
specifiers do match.
On 08/09/2022 11:24 AM, Synopsis wrote:
On Wednesday, 7 September 2022 at 23:06:44 UTC, rikki cattermole wrote:
Text in buffer: "123\n"
Read: "123"
Text in buffer: "\n"
Read: exception, expecting number for "\n"
Changing your readf format specifier to include the new line should work.
On Wednesday, 7 September 2022 at 23:06:44 UTC, rikki cattermole
wrote:
Text in buffer: "123\n"
Read: "123"
Text in buffer: "\n"
Read: exception, expecting number for "\n"
Changing your readf format specifier to include the new line
should work.
Text in buffer: "123\n"
Read: "123"
Text in buffer: "\n"
Read: exception, expecting number for "\n"
Changing your readf format specifier to include the new line should work.
https://dlang.org/phobos/std_stdio.html#.File.readf