GaloisInc / saw-script

The SAW scripting language.
BSD 3-Clause "New" or "Revised" License
442 stars 63 forks source link

saw-core position reporting doesn't print correctly #2140

Open sauclovian-g opened 2 weeks ago

sauclovian-g commented 2 weeks ago
sawscript> parse_core "gibberish;"
[00:40:45.385] PosPair {_pos = Pos {posBase = "<interactive>", posPath = "<interactive>", posLine = 1, posCol = 9}, val = UnexpectedToken (TKey ";")}

Stack trace:
"parse_core" (<stdin>:1:1-1:11)
PosPair {_pos = Pos {posBase = "<interactive>", posPath = "<interactive>", posLine = 1, posCol = 9}, val = UnexpectedToken (TKey ";")}

sawscript> 

It appears to be using Show on the saw-core position type, and the Show instance isn't suitable.