Closed Bug 1403345 Opened 2 years ago Closed 2 years ago

Rename nsReferencedElement to dom::IDTracker

Categories

(Core :: SVG, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla58
Tracking Status
firefox57 --- wontfix
firefox58 --- fixed

People

(Reporter: jwatt, Assigned: jwatt)

References

Details

Attachments

(3 files)

The name of the class nsReferencedElement (and it's location in dom/base) makes it sound like it's an nsIContent sub-class. In fact there is no inheritance relationship between nsReferencedElement and nsIContent (or dom::Element). This is in fact just a helper class to keep track of which element is pointed to by a given ID in a document.
Attachment #8912419 - Flags: review?(longsonr) → review+
Attachment #8912420 - Flags: review?(longsonr) → review+
Comment on attachment 8912423 [details] [diff] [review]
part 3 - Rename nsReferencedElement to dom::IDTracker

> 
>-  class TimeReferenceElement : public nsReferencedElement
>+  class TimeReferenceElement : public mozilla::dom::IDTracker

Rename this class, either here or as a follow up. TimeReferenceTracker?

> 
>-  class TargetReference : public nsReferencedElement {
>+  class TargetReference : public mozilla::dom::IDTracker {

rename to TargetReferenceTracker?

> 
> protected:
>-  class PathReference : public nsReferencedElement {
>+  class PathReference : public mozilla::dom::IDTracker {

rename to MPathElementTracker?

> protected:
>-  class SourceReference : public nsReferencedElement {
>+  class SourceReference : public mozilla::dom::IDTracker {

rename to SourceElementTracker?

> 
>-  class SourceReference : public nsReferencedElement
>+  class SourceReference : public IDTracker

rename to SourceElementTracker?

all these could be done in a follow up if you want. Element in names optional.
Attachment #8912423 - Flags: review?(longsonr) → review+
Pushed by jwatt@jwatt.org:
https://hg.mozilla.org/integration/mozilla-inbound/rev/4c769ea344a0
part 1 - Add missing include to nsReferencedElement.h. r=longsonr
https://hg.mozilla.org/integration/mozilla-inbound/rev/59252e3229f1
part 2 - Move nsReferencedElement.h/.cpp to IDTracker.h/.cpp. r=longsonr
https://hg.mozilla.org/integration/mozilla-inbound/rev/1b5d3684ecfb
part 3 - Rename nsReferencedElement to dom::IDTracker. r=longsonr
Backed out for busted Linux x64 asan opt fuzzing builds:

https://hg.mozilla.org/integration/mozilla-inbound/rev/4006cb517f6c9432f2047de278e9e803d798a72a
https://hg.mozilla.org/integration/mozilla-inbound/rev/37db8c4ccf5c66ead5b5554e343694a1169f366e
https://hg.mozilla.org/integration/mozilla-inbound/rev/3507f299b3581056cd117906e70328eacf844963

Push with failure: https://treeherder.mozilla.org/#/jobs?repo=mozilla-inbound&revision=791d50892077f250a17935f239978769b5a535e2&filter-resultStatus=testfailed&filter-resultStatus=busted&filter-resultStatus=exception&filter-resultStatus=retry&filter-resultStatus=usercancel&filter-resultStatus=runnable
Failure log: https://treeherder.mozilla.org/logviewer.html#?job_id=133517924&repo=mozilla-inbound

[task 2017-09-27T07:56:26.687Z] 07:56:26     INFO -  In file included from /builds/worker/workspace/build/src/obj-firefox/dom/base/Unified_cpp_dom_base4.cpp:2:
[task 2017-09-27T07:56:26.687Z] 07:56:26     INFO -  In file included from /builds/worker/workspace/build/src/dom/base/TimeoutExecutor.cpp:7:
[task 2017-09-27T07:56:26.688Z] 07:56:26     INFO -  /builds/worker/workspace/build/src/dom/base/TimeoutExecutor.h:21:3: error: unknown type name 'TimeoutManager'
[task 2017-09-27T07:56:26.688Z] 07:56:26     INFO -    TimeoutManager* mOwner;
[task 2017-09-27T07:56:26.689Z] 07:56:26     INFO -    ^
[task 2017-09-27T07:56:26.690Z] 07:56:26     INFO -  /builds/worker/workspace/build/src/dom/base/TimeoutExecutor.h:22:3: error: unknown type name 'nsCOMPtr'
[task 2017-09-27T07:56:26.691Z] 07:56:26     INFO -    nsCOMPtr<nsITimer> mTimer;
[task 2017-09-27T07:56:26.691Z] 07:56:26     INFO -    ^
[task 2017-09-27T07:56:26.692Z] 07:56:26     INFO -  /builds/worker/workspace/build/src/dom/base/TimeoutExecutor.h:22:11: error: expected member name or ';' after declaration specifiers
[task 2017-09-27T07:56:26.701Z] 07:56:26     INFO -    nsCOMPtr<nsITimer> mTimer;
[task 2017-09-27T07:56:26.701Z] 07:56:26     INFO -    ~~~~~~~~^
[task 2017-09-27T07:56:26.701Z] 07:56:26     INFO -  /builds/worker/workspace/build/src/dom/base/TimeoutExecutor.h:72:28: error: unknown type name 'TimeoutManager'
[task 2017-09-27T07:56:26.701Z] 07:56:26     INFO -    explicit TimeoutExecutor(TimeoutManager* aOwner);
[task 2017-09-27T07:56:26.701Z] 07:56:26     INFO -                             ^
Flags: needinfo?(jwatt)
Unified bustage that didn't show up on the Linux 64 Try push.
Flags: needinfo?(jwatt)
Pushed by jwatt@jwatt.org:
https://hg.mozilla.org/integration/mozilla-inbound/rev/302d3fb2a660
part 1 - Add missing include to nsReferencedElement.h. r=longsonr
https://hg.mozilla.org/integration/mozilla-inbound/rev/4af144ee3dea
part 2 - Add missing includes and class declarations to TimeoutExecutor.h. r=me
https://hg.mozilla.org/integration/mozilla-inbound/rev/47e852b8e34a
part 3 - Move nsReferencedElement.h/.cpp to IDTracker.h/.cpp. r=longsonr
https://hg.mozilla.org/integration/mozilla-inbound/rev/c404bb3b5af7
part 4 - Rename nsReferencedElement to dom::IDTracker. r=longsonr
Blocks: 1403500
Pushed by jwatt@jwatt.org:
https://hg.mozilla.org/integration/mozilla-inbound/rev/cdb9b6b2f6df
part 5 - Fix unified build bustage by adding missing includes to TimeoutExecutor.cpp. r=me
Duplicate of this bug: 1272632
You need to log in before you can comment on or make changes to this bug.