fix #16025 repr now consistent: does not insert trailing newline (#16034)

This commit is contained in:
Timothee Cour 2020-11-19 12:12:51 -08:00 • committed by GitHub
commit b3c3557c33
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
12 changed files with 105 additions and 84 deletions

View file

@ -237,4 +237,5 @@ proc reprAny(p: pointer, typ: PNimType): string {.compilerRtl.} =
var cl: ReprClosure
initReprClosure(cl)
reprAux(result, p, typ, cl)
add(result, "\n")
when defined(nimLegacyReprWithNewline): # see PR #16034
add result, "\n"