c - How to preserve new lines when doing: #include "file" -
the file has empty new lines.
"a" "" "b" "" "c" file included program via following method
fputs ( #include "file" ,stdout ); actual result:
abc expected result:
a b c
c merges string literals separated whitespace. when write
"a" "" "b" "" "c" c compiler merges them "abc"; cannot detect difference between 2 sources once code compiled.
if want line breaks, insert them string literals explicitly:
"a\n" "\n" "b\n" "\n" "c"
Comments
Post a Comment