don't confuse Emacs' syntax highlighting

This commit is contained in:
Gwenhael Le Moine 2022-10-11 13:34:52 +02:00
parent d54bebdcec
commit 31443519e8
No known key found for this signature in database
GPG key ID: FDFE3669426707A7

View file

@ -46,7 +46,8 @@ class RplRepl
if input.strip == 'edit'
prefill = @interpreter.stack.pop.to_s
elsif input.strip == 'history'
@interpreter.run( "{ #{Reline::HISTORY.map { |line| "\"#{line}\"" }.join(' ')} }" )
history = Reline::HISTORY.map { |line| "\"#{line}\"" }.join(' ')
@interpreter.run( "{ #{history} }" )
elsif input.empty?
# Remove blank lines from history
Reline::HISTORY.pop