Bug
An arrow-literal assigned to a field inside a class constructor body emits malformed LLVM IR: store i8* __lambda_N, ... missing the @ sigil. Clang rejects the IR.
Example shape:
class Foo {
cb: (x: string) => void;
constructor() {
this.cb = (x) => console.log(x); // ← codegen emits broken IR here
}
}
Workaround used in lib/net.ts (PR #585): declare a module-level named function (e.g., _netNoopCb) and assign the reference: this.cb = _netNoopCb.
Impact
Blocks idiomatic class initialization with callback fields. Forces module-level helpers that bloat the lib surface.
Likely fix location
src/codegen/ — lambda name emission. Probably a one-character fix (missing @ prefix in the IR print step).
Bug
An arrow-literal assigned to a field inside a class constructor body emits malformed LLVM IR:
store i8* __lambda_N, ...missing the@sigil. Clang rejects the IR.Example shape:
Workaround used in
lib/net.ts(PR #585): declare a module-level named function (e.g.,_netNoopCb) and assign the reference:this.cb = _netNoopCb.Impact
Blocks idiomatic class initialization with callback fields. Forces module-level helpers that bloat the lib surface.
Likely fix location
src/codegen/— lambda name emission. Probably a one-character fix (missing@prefix in the IR print step).