fix pipe issue in REPL, add ability to dump top in repl
This commit is contained in:
@@ -47,6 +47,9 @@ export let shim: NodeShim = {
|
||||
writeFileSync(name: string, data: string, enc?: string) {
|
||||
shim.files[name] = new TextEncoder().encode(data)
|
||||
},
|
||||
writeSync(fd: number, data: string) {
|
||||
shim.stdout += data;
|
||||
}
|
||||
},
|
||||
process: {
|
||||
argv: ["", ""],
|
||||
|
||||
@@ -484,6 +484,7 @@ const processOutput = (
|
||||
let endLineNumber = +eline;
|
||||
let endColumn = +ecol
|
||||
// FIXME - pass the real path in
|
||||
if (file.startsWith("./")) file = file.slice(2);
|
||||
if (fn && fn !== file) {
|
||||
startLineNumber = startColumn = 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user