effekt-lang / effekt-lang/effekt
Special characters in file names break `js` backend
Open
bug
- Dominant language
- Scala
- Stars
- 469
- Forks
- 41
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 23
Description
The file name just gets inserted into js as a identifier names, so `./examples/llvm/hello-world.effekt`
generates the following js code:
```javascript
const $effekt = require("./effekt.js");
const $hello-world = { };
function main() {
const tmp344 = $effekt.println("hello world");
return $effekt.pure(tmp344);
}
module.exports = Object.assign($hello-world, { main: main });
```
Which is not correct js, as `-` can't be part of an identifier.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.