Bun AOT Compiler False Positive 'property-added' on Class Inheritance
- Investigating(current)
- Trending(upcoming)
- Workaround available(upcoming)
- Resolved(upcoming)
Executive summary
Bun 1.4.4-canary.1+7ca0042d3 suffers from a false positive 'property-added' warning during AOT compilation when a property declared in a base class is mutated within a subclass method.
No verified workaround yet
None of the linked reports describe a mitigation. Follow this incident to hear when one appears.
Official fixUnder active investigation. No report has identified a root cause yet.
Evidence
1 report · 1 GitHubShow
- [1]GitHub First reportAOT: false positive 'property-added' on class inheritance when a property declared in Base is mutated in a method(opens GitHub issue in a new tab)
What version of Bun is running? 1.4.4-canary.1+7ca0042d3 What platform is your computer? Linux 6.8.0-142-lowlatency x86_64 x86_64 What steps can reproduce the bug? When a subclass Sub extends Base inherits fields declared in Base, mutating any declared field on this inside a method causes bun compile --explain to flag the Base constructor with property-added (why: object-changed, types: Sub). Minimal self-contained reproducer: // repro_subclass.ts class Base { protected readonly _x: number…
by yoch 0upvotes 0comments
Timeline
- First report on GitHub issue
AOT: false positive 'property-added' on class inheritance when a property declared in Base is mutated in a method
Source