Closed
Bug 638998
Opened 14 years ago
Closed 14 years ago
Need a way to specify that classes can't be constructed from AS3, only C++
Categories
(Tamarin Graveyard :: Virtual Machine, defect)
Tamarin Graveyard
Virtual Machine
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: stejohns, Assigned: stejohns)
Details
Attachments
(1 file)
|
203.88 KB,
patch
|
rreitmai
:
review+
edwsmith
:
superreview+
lhansen
:
feedback+
|
Details | Diff | Splinter Review |
It's another common use case in Flash/AIR; we should support it directly in nativegen, rather than continue to use the convoluted constructRestrictedObject() call.
| Assignee | ||
Comment 1•14 years ago
|
||
This allows construct="native" to mean "cannot be instantiated from AS3, ever"; the only way to construct such an object is via its classes constructObject() method, called from C++.
Assignee: nobody → stejohns
Attachment #517058 -
Flags: superreview?(edwsmith)
Attachment #517058 -
Flags: review?(rreitmai)
Comment 2•14 years ago
|
||
Would an alternative be to fast-track the "private/namespaced constructor" language change that's slated for this year, or is that too wrenching / too long to wait?
I'm asking because what's going on here is that you have a constructor that's in a namespace that only the C++ code has access to.
(At least let's make sure the two mechanisms will be compatible. I'll inspect this patch further tomorrow.)
| Assignee | ||
Comment 3•14 years ago
|
||
Too long to wait, IMHO; rationalizing all the construction paths in C++ is a gating factor for ANI. Additionally, the current implementation of constructRestrictedObject() in Flash is too horrible for words (or for sharing in public).
| Assignee | ||
Comment 4•14 years ago
|
||
Comment on attachment 517058 [details] [diff] [review]
Patch
Adding Lars, to get feedback on whether this mechanism will likely work well with the future restricted-ctor language work.
Attachment #517058 -
Flags: feedback?(lhansen)
Updated•14 years ago
|
Attachment #517058 -
Flags: review?(rreitmai) → review+
Comment 5•14 years ago
|
||
Comment on attachment 517058 [details] [diff] [review]
Patch
Seems reasonable.
Attachment #517058 -
Flags: feedback?(lhansen) → feedback+
Comment 6•14 years ago
|
||
changeset: 6063:f4943b15ab15
user: Steven Johnson <stejohns@adobe.com>
summary: Bug 638998 - Need a way to specify that classes can't be constructed from AS3, only C++ (r=rreitmai)
http://hg.mozilla.org/tamarin-redux/rev/f4943b15ab15
Comment 7•14 years ago
|
||
changeset: 6066:2c605c7887fa
user: Steven Johnson <stejohns@adobe.com>
summary: Bug 638998 followup: NativeBaseClass construction needs to be skipped in -Dverifyonly mode (r=me)
http://hg.mozilla.org/tamarin-redux/rev/2c605c7887fa
Comment 8•14 years ago
|
||
changeset: 6071:ba14945d29db
user: Steven Johnson <stejohns@adobe.com>
summary: Bug 638998 followup: NativeBaseClass construction needs to be skipped in -Dverifyonly mode; applying for the second time as change 6067:4bd8f4b4fa01 accidentally reverted this change, sigh (r=me again)
http://hg.mozilla.org/tamarin-redux/rev/ba14945d29db
Comment 9•14 years ago
|
||
Comment on attachment 517058 [details] [diff] [review]
Patch
ClassClosure.cpp:190
> // tbhis
typo, caps, please fix in TR.
Attachment #517058 -
Flags: superreview?(edwsmith) → superreview+
Comment 10•14 years ago
|
||
changeset: 6076:9758cb0c4682
user: Steven Johnson <stejohns@adobe.com>
summary: Bug 638998 followup: fix type in comment (r=edwsmith)
http://hg.mozilla.org/tamarin-redux/rev/9758cb0c4682
| Assignee | ||
Updated•14 years ago
|
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•