highlight() adds newline to the end of a single line expression

Issue #1403 new
Aaron Meurer
created an issue
>>> highlight('1', Python3Lexer(), pygments.formatters.Terminal256Formatter())
'\x1b[38;5;241m1\x1b[39m\n'

It's a bit annoying that it adds a newline at the end when the input expression has no newlines.

Comments (0)

  1. Log in to comment