Closed Bug 1277628 Opened 8 years ago Closed 8 years ago

gdb pretty printers don't handle GCPtr

Categories

(Core :: JavaScript Engine, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla49
Tracking Status
firefox49 --- fixed

People

(Reporter: tromey, Assigned: tromey)

Details

Attachments

(1 file)

I've been getting exceptions like this when debugging:

04b4db890 <XPC_WN_OnlyIWrite_AddPropertyStub(JSContext*, JS::Handle<JSObject*>, JS::Handle<jsid>, JS::Handle<JS::Value>)>, obj=Traceback (most recent call last):
  File "/home/tromey/firefox-git/gecko/js/src/gdb/mozilla/prettyprinters.py", line 341, in to_string
    summary = self.summary()
  File "/home/tromey/firefox-git/gecko/js/src/gdb/mozilla/JSObject.py", line 35, in summary
    group = deref(self.value['group_'])
  File "/home/tromey/firefox-git/gecko/js/src/gdb/mozilla/Root.py", line 88, in deref
    raise NotImplementedError
NotImplementedError


I found these are caused by Root.py:deref not handling GCPtr.
I'll attach a patch in a bit.
This avoids an error when trying to deref a GCPtr; and also adds the tag
to the NotImplementedError to make it simpler to fix similar bugs in the
future.

Review commit: https://reviewboard.mozilla.org/r/57250/diff/#index_header
See other reviews: https://reviewboard.mozilla.org/r/57250/
Attachment #8759269 - Flags: review?(sphink)
Comment on attachment 8759269 [details]
Bug 1277628 - handle js::GCPtr in gdb pretty-printers;

https://reviewboard.mozilla.org/r/57250/#review54096
Attachment #8759269 - Flags: review?(sphink) → review+
Try doesn't run the tests for this yet, so no try run.
Keywords: checkin-needed
Pushed by cbook@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/f729fa97d3a7
handle js::GCPtr in gdb pretty-printers. r=sfink
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/f729fa97d3a7
Status: ASSIGNED → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla49
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: