-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
compile time echo steals newline from stderr so it's included in stdout instead #16334
Labels
Comments
RSDuck
added a commit
to RSDuck/Nim
that referenced
this issue
Dec 12, 2020
RSDuck
added a commit
to RSDuck/Nim
that referenced
this issue
Dec 12, 2020
when true:
when defined case2a:
static: echo "test"
nonexistant
else:
import os, osproc, streams
let process = startProcess(getCurrentCompilerExe(), args = ["check", "-f", "-d:case2a", currentSourcePath], options = {poUsePath})
discard process.waitForExit()
echo "std out:"
echo process.outputStream().readAll()
echo "std err:"
echo process.errorStream().readAll() prints:
|
This was referenced Dec 27, 2020
mildred
pushed a commit
to mildred/Nim
that referenced
this issue
Jan 11, 2021
* fix nim-lang#16334 * rename isstdout -> isStdout * separate lastMsgWasDot for stdout and stderr * simplify logic
ardek66
pushed a commit
to ardek66/Nim
that referenced
this issue
Mar 26, 2021
* fix nim-lang#16334 * rename isstdout -> isStdout * separate lastMsgWasDot for stdout and stderr * simplify logic
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Example
Say we have this program saved as test.nim
And we inspect stdout and stderr using this program (if you're a command line wiz you could probably do that simpler):
Current Output
there's no newline between the dots and the path. But an additional one in stdout.
If the echo is removed this is the output:
Additional Information
The text was updated successfully, but these errors were encountered: