Closed Bug 1736707 Opened 3 years ago Closed 3 years ago

Get rid of nsContentUtils::sNameSpaceManager

Categories

(Core :: DOM: Core & HTML, task, P4)

task

Tracking

()

RESOLVED FIXED
95 Branch
Tracking Status
firefox95 --- fixed

People

(Reporter: mccr8, Assigned: mccr8)

References

Details

Attachments

(2 files)

This seems pointless. Maybe this was some kind of ancient optimization. We can call nsNameSpaceManager::GetInstance() instead of nsContentUtils::NameSpaceManager().

Emilio, I'm trying to get rid of nsContentUtils::sNameSpaceManager, but there's a reference to it in the form of structs::nsContentUtils_sNameSpaceManager in servo/components/style/gecko/wrapper.rs. I tried to change that to structs::nsNameSpaceManager_sInstance, which seems to exist in structs.rs, but I get the error "cannot find value nsNameSpaceManager_sInstance in module structs" when I try to build it. Do you know what I might be doing wrong? Thanks.

Flags: needinfo?(emilio)

(This is not urgent at all, in case that's not obvious...)

You need to whitelist that static explicitly, will send a patch.

Flags: needinfo?(emilio)

Call nsNameSpaceManager::GetInstance() instead.

nsNameSpaceManager::sInstance and nsContentUtils::sNameSpaceManager aren't cleared at precisely the same point in shutdown, and the former will be recreated if it is accessed after it was cleared, but hopefully that doesn't matter.

Pushed by amccreight@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/41958fb8de30
part 1 - Get rid of nsContentUtils::NameSpaceManager(). r=peterv
https://hg.mozilla.org/integration/autoland/rev/849b7e5b8220
part 2 - Remove nsContentUtils::sNameSpaceManager. r=peterv
Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 95 Branch
See Also: → 1727259
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: