How to write stderr in Nim?

I know there is echoone that writes to stdout. Is it possible to redirect echoto stderr, or is there any other way to write to stderr?

+4
source share
1 answer

It is impossible to redirect echo, but the same can be achieved using writeLinein the descriptor stderr(special import is not required):

stderr.writeLine("Error: ", 42)

Documentation links:

+6
source

Source: https://habr.com/ru/post/1688036/


All Articles