Closed Bug 303817 Opened 19 years ago Closed 19 years ago

[FIX]const nsAFlatString& GetDocumentTitle() const. May return null. oh really?

Categories

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

defect

Tracking

()

RESOLVED FIXED
mozilla1.9alpha1

People

(Reporter: timeless, Assigned: bzbarsky)

References

()

Details

Attachments

(1 file, 1 obsolete file)

135    * Return the title of the document. May return null.
oh really?
136    */
137   const nsAFlatString& GetDocumentTitle() const
138   {
139     return mDocumentTitle;
Attached patch Fix docs (obsolete) — Splinter Review
Assignee: general → bzbarsky
Status: NEW → ASSIGNED
Attachment #203623 - Flags: superreview?(jst)
Attachment #203623 - Flags: review?(jst)
OS: MacOS X → All
Priority: -- → P4
Hardware: Macintosh → All
Summary: const nsAFlatString& GetDocumentTitle() const. May return null. oh really? → [FIX]const nsAFlatString& GetDocumentTitle() const. May return null. oh really?
Target Milestone: --- → mozilla1.9alpha
Comment on attachment 203623 [details] [diff] [review]
Fix docs

+   * Return the title of the document.  May return a void string (one for which
+   * calling .get() returns null) if there is no title for this document).
    */
   const nsString& GetDocumentTitle() const

that comment is wrong. nsString will never return null for .get(), only nsXPIDLString will.

(btw, did you intentionally have parts of the content-id-removal patch in this one?)
> nsString will never return null for .get(), only nsXPIDLString will.

Ah, ok.  I thought that a IS_VOID string would return null.  I'll fix that comment accordingly.

> did you intentionally have parts of the content-id-removal patch 

Nope.
Attached patch Fix docs betterSplinter Review
Attachment #203623 - Attachment is obsolete: true
Attachment #203734 - Flags: superreview?(jst)
Attachment #203734 - Flags: review?(jst)
Attachment #203623 - Flags: superreview?(jst)
Attachment #203623 - Flags: review?(jst)
Comment on attachment 203734 [details] [diff] [review]
Fix docs better

r+sr=jst
Attachment #203734 - Flags: superreview?(jst)
Attachment #203734 - Flags: superreview+
Attachment #203734 - Flags: review?(jst)
Attachment #203734 - Flags: review+
Fixed.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Flags: in-testsuite-
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: