Closed ehildenb closed 2 years ago
Why isn't the local build picking up the latest tags?
v5.2.21-44-gd7d340bd4f
I get the same behavior on my PC.
If you remove --gen-glr-bison-parser
it's fine.
This appears to be a bug in how the kparse script (and probably other scripts) handle the case when the --output-file
command line flag is not specified, and the file descriptor for stdout on the kparse script is redirected to a file rather than a terminal. I will investigate the best way to address this in each script where this current design pattern is being used.
K Version
Description
kparse
is truncating the output of any file it's redirected to when using--gen-glr-bisor-parser
. This results in weird behavior on CI (output looks strange).Input Files
File
test.k
:File
pgm1.teal
:File
pgm2.teal
:Reproduction Steps
Kompile the semantics with
--gen-glr-parser
, then callkparse
on both programs (one after the other), redirecting the output to fileoutput
, and look at the contents of fileoutput
between each step. Note that we are using appending redirect for the second call tokparse
. Also note that this reproduces on CI (an Ubuntu Focal image, and I'm also on Ubuntu Focal).Note that I injected an extra blank line before each prompt for readability (the prompts are denoted with
%
).Expected Behavior
I expect
kparse
to not truncate whatever stream it's writing to when using the bison parser output. So the finalcat output
should result in: