Closed
Bug 792790
Opened 12 years ago
Closed 12 years ago
Adapt translator/Java source to nullptr
Categories
(Core :: DOM: HTML Parser, defect)
Core
DOM: HTML Parser
Tracking
()
RESOLVED
FIXED
mozilla18
People
(Reporter: hsivonen, Assigned: hsivonen)
References
Details
Attachments
(1 file, 3 obsolete files)
24.14 KB,
patch
|
smaug
:
review+
|
Details | Diff | Splinter Review |
The global change from nsnull to nullptr manually changed generated parser code so that some nsnull instances became nullptr and some became 0. Need to change the translator and/or the Java code so that translation results in proper nsnull-free output.
Assignee | ||
Updated•12 years ago
|
Summary: Adapts traslator/Java source to nullptr → Adaps translator/Java source to nullptr
Assignee | ||
Updated•12 years ago
|
Summary: Adaps translator/Java source to nullptr → Adapt translator/Java source to nullptr
Assignee | ||
Comment 1•12 years ago
|
||
The cases where nsnull was changed to 0 instead of nullptr in the files that are supposed to be generated fell into two categories:
1) Invoking the special operator= in autoJArray
2) Representing undefined namespace when the accessor is called with an out-of-bounds index.
I addressed the first case by editing jArray.h. To address the second case, I opted to remove the handling for out-of-bounds indeces, because the accessors are always called with a valid index into Gecko thanks to the way the index is obtained at all call sites. On the Java side, I added variants of the by-index accessors that's don't check for out-of-bounds. I then exposed to these new accessors to C++ instead of the old ones. The assertions that I added on the Java side but that don't get translated to C++ yet are there in anticipation of bug 503190. Note that the assertions are unnecessary in Java, because the JVM is guaranteed to check for array bounds anyway.
Assignee: nobody → hsivonen
Status: NEW → ASSIGNED
Assignee | ||
Comment 2•12 years ago
|
||
Attachment #662963 -
Attachment is obsolete: true
Attachment #664889 -
Flags: review?(bugs)
Assignee | ||
Comment 3•12 years ago
|
||
Comment on attachment 664889 [details] [diff] [review]
Adapt to nullptr, with OS X compiler support
Argh. This still causes compiler warnings.
Attachment #664889 -
Flags: review?(bugs)
Assignee | ||
Comment 4•12 years ago
|
||
I give up trying to get rid of compiler warnings. In GCC 4.6.3 decltype(nullptr) seems to be long int rather than std::nullptr_t. Sigh.
Attachment #664889 -
Attachment is obsolete: true
Assignee | ||
Comment 5•12 years ago
|
||
Attachment #664931 -
Attachment is obsolete: true
Attachment #665344 -
Flags: review?(bugs)
Updated•12 years ago
|
Attachment #665344 -
Flags: review?(bugs) → review+
Assignee | ||
Comment 6•12 years ago
|
||
Thanks for the r+.
https://hg.mozilla.org/integration/mozilla-inbound/rev/b7cc4a94a649
Comment 7•12 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 12 years ago
Flags: in-testsuite-
Resolution: --- → FIXED
Target Milestone: --- → mozilla18
You need to log in
before you can comment on or make changes to this bug.
Description
•