Skip to content

Commit

Permalink
fix syntax error in closures.nemo
Browse files Browse the repository at this point in the history
  • Loading branch information
kritzcreek committed Aug 21, 2024
1 parent 6be1aed commit 23099ac
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 13 deletions.
2 changes: 1 addition & 1 deletion crates/cli/tests/run/closures.nemo
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import log : fn (i32) -> unit from log

fn main() {
let x = (fn (x : i32) -> i32 { x + 1 })(10);
log(x)
log(x);

let twice = {
fn (f : fn (i32) -> i32) -> fn(i32) -> i32 {
Expand Down
12 changes: 5 additions & 7 deletions crates/cli/tests/snapshots/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,11 @@ info:
NO_COLOR: "1"
input_file: crates/cli/tests/run/closures.nemo
---
success: false
exit_code: 1
success: true
exit_code: 0
----- stdout -----
11
5
0

----- stderr -----
error: Uncaught (in promise) NotFound: No such file or directory (os error 2): readfile 'tests/build/closures.wasm'
const wasmCode = await Deno.readFile(filePath);
^
at Object.readFile (ext:deno_fs/30_fs.js:848:24)
at [FILE_PATH]
7 changes: 2 additions & 5 deletions crates/cli/tests/snapshots/[email protected]
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,8 @@ info:
RUST_BACKTRACE: "0"
input_file: crates/cli/tests/run/closures.nemo
---
success: false
exit_code: 101
success: true
exit_code: 0
----- stdout -----

----- stderr -----
thread 'main' panicked at crates/frontend/src/lib.rs:105:13:
No IR generated, despite no errors
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

0 comments on commit 23099ac

Please sign in to comment.