nsIAtom has been deCOMtaminated and is now called nsAtom

Greetings,

I have been deCOMtaminating nsIAtom over the past two months:
https://bugzilla.mozilla.org/show_bug.cgi?id=1392883.

A big step that landed over a week ago was the devirtualization of nsIAtom,
which means it is no longer a subclass of nsISupports:
https://bugzilla.mozilla.org/show_bug.cgi?id=1400459.

And I just landed (on autoland) the final step of renaming nsIAtom as
nsAtom. This is tracked at
https://bugzilla.mozilla.org/show_bug.cgi?id=1400460.

Apologies for any conflicts or problems caused in outstanding patches. For
patches less than 1.5 weeks old (i.e. post-devirtualization) it's very
likely that simply replacing all nsIAtom occurrences with nsAtom will
suffice. For patches older than that here is a summary of changes that
might be required.

- nsIAtom --> nsAtom

- nsCOMPtr<nsIAtom> --> RefPtr<nsAtom>

- nsCOMArray<nsIAtom> --> nsTArray<RefPtr<nsAtom>>
  - Count() --> Length()
  - ObjectAt() --> ElementAt()
  - AppendObject() --> AppendElement()
  - RemoveObjectAt() --> RemoveElementAt()

- ns*Hashtable<nsISupportsHashKey, ...> -->
  ns*Hashtable<nsRefPtrHashKey<nsAtom>, ...>

- nsInterfaceHashtable<T, nsIAtom> --> nsRefPtrHashtable<T, nsAtom>

  # If the array contains atoms.
- nsCOMPtr<nsIMutableArray> --> nsTArray<RefPtr<nsAtom>>
  - nsArrayBase::Create() --> nsTArray()
  - GetLength() --> Length()
  - do_QueryElementAt() --> operator[]

Nick
0
Nicholas
10/9/2017 2:27:00 AM
mozilla.dev.platform 6108 articles. 0 followers. Post Follow

0 Replies
28 Views

Similar Articles

[PageSpeed] 49

Reply: