Open Bug 1128298 Opened 9 years ago Updated 2 years ago

Implement StructType.extend in Typed Objects API

Categories

(Core :: JavaScript Engine, defect)

x86_64
Windows 8.1
defect

Tracking

()

People

(Reporter: kael, Unassigned)

References

()

Details

(Keywords: dev-doc-needed, Whiteboard: [DocArea=JS])

Many use cases for structured types, like representing C#/Java style objects, require some basic form of inheritance.

Implementing the proposed 'extend' API for StructType would address a number of these scenarios:

https://github.com/nikomatsakis/typed-objects-explainer/blob/master/ootypes.md

From my discussion with Luke, we agreed that for a 1.0 of this feature, shadowing a name from a base class in a derived class should throw at the time of the .extend() call. This eliminates the need to provide crazy super()/.base style mechanisms. Applications that want to do shadowing can do it manually, by creating mangled names and then exposing them via properties with unmangled names.
Keywords: dev-doc-needed
Whiteboard: [DocArea=JS]
Severity: normal → S3
You need to log in before you can comment on or make changes to this bug.