repl: dont save line if last compilation errored
parent
f654c4af7a
commit
aae063b9ad
|
@ -1375,7 +1375,9 @@ fn run_repl() []string {
|
||||||
s := os.exec('$vexe run $temp_file -repl') or {
|
s := os.exec('$vexe run $temp_file -repl') or {
|
||||||
panic(err)
|
panic(err)
|
||||||
}
|
}
|
||||||
|
if !s.exit_code {
|
||||||
lines << line
|
lines << line
|
||||||
|
}
|
||||||
vals := s.output.split('\n')
|
vals := s.output.split('\n')
|
||||||
for i:=0; i<vals.len; i++ {
|
for i:=0; i<vals.len; i++ {
|
||||||
println(vals[i])
|
println(vals[i])
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
a
|
||||||
|
33
|
||||||
|
===output===
|
||||||
|
.vrepl_temp.v:2 undefined: `a`
|
||||||
|
33
|
Loading…
Reference in New Issue