fix https://github.com/timotheecour/Nim/issues/152: avoid writing spurious ^[[0m to stderr when callStyledWriteLineStderr not called (#14214)

* fix https://github.com/timotheecour/Nim/issues/152 `^[[0m` is inserted in stderr for `echo code | nim c -`

* resetAttributes not even needed, already handled in styledWriteLine

* simplify tests in tests/trunner.nim thanks to this fix
This commit is contained in:
Timothee Cour 2020-05-04 06:07:32 -07:00 • committed by GitHub
commit a23302ef56
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 12 deletions

View file

@ -405,5 +405,3 @@ proc mainCommand*(graph: ModuleGraph) =
echo " int tries: ", gCacheIntTries
echo " efficiency: ", formatFloat(1-(gCacheMisses.float/gCacheTries.float),
ffDecimal, 3)
resetAttributes(conf)