You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(faces): strip trailing ; from module name in JaffaScript imports (#120)
`transform_import` extracted the module name by stripping surrounding
quote characters with `String.sub mod_part 1 (len - 2)`. When the
import ends with a semicolon (the normal JS style: `import { x } from
\"m\";`), `mod_part` is `\"m\";` — the last character is `;`, not `\"`, so
the slice kept the trailing `\"` in the module name and produced
`use m\"::{x};` instead of `use m::{x};`.
Fix: in all three import branches (`import { x }`, `import *`, and
`import name`), strip a trailing `;` from `mod_part` / `quoted` before
the quote-stripping slice.
Updated `examples/faces/hello-jaffa.affine` to include
`import { println } from \"io\";` so the import path is exercised by the
regression test. Updated snapshot.
0 commit comments