mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1250396 (part 1) - Document a subtle contraint on nsIAtom. r=froydnj.
This commit is contained in:
parent
fbd198e373
commit
85d2dc6c54
@ -53,10 +53,12 @@ interface nsIAtom : nsISupports
|
||||
}
|
||||
|
||||
inline void ToString(nsAString& aBuf) {
|
||||
// See the comment on |mString|'s declaration.
|
||||
nsStringBuffer::FromData(mString)->ToString(mLength, aBuf);
|
||||
}
|
||||
|
||||
inline nsStringBuffer* GetStringBuffer() const {
|
||||
// See the comment on |mString|'s declaration.
|
||||
return nsStringBuffer::FromData(mString);
|
||||
}
|
||||
|
||||
@ -72,6 +74,11 @@ interface nsIAtom : nsISupports
|
||||
protected:
|
||||
uint32_t mLength;
|
||||
uint32_t mHash;
|
||||
/**
|
||||
* WARNING! There is an invisible constraint on |mString|: the chars it
|
||||
* points to must belong to an nsStringBuffer. This is so that the
|
||||
* nsStringBuffer::FromData() calls above are valid.
|
||||
*/
|
||||
char16_t* mString;
|
||||
%}
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user