effekt-lang / effekt-lang/effekt
Optimize nullary constructors to singletons on JavaScript
Open
area:compiler
area:js
- Dominant language
- Scala
- Stars
- 469
- Forks
- 41
- Avg merge
- 1d 16h
- Merged PRs (30d)
- 23
Description
Constructors such as `Nil()` and `None()` are created anew every time, but we could have a singleton instance to avoid creating the object every single time it's used.
Needs benchmarking.
Contributor guide
No contributing guide indexed for this repository
Research direction
No files or tests are named. Start by locating the JavaScript code-generation path for nullary constructors such as Nil() and None(), then identify how repeated instances are created. Add benchmarking for the current and optimized behavior, with completion requiring singleton reuse and benchmark results showing whether allocation is reduced.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, scala
- Domain
- compilers, performance
- Issue type
- Refactor
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100