Closed Bug 1337365 Opened 7 years ago Closed 7 years ago

Fix non-standard API use in testGCHeapPostBarriers test

Categories

(Core :: JavaScript: GC, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla54
Tracking Status
firefox54 --- fixed

People

(Reporter: jonco, Assigned: jonco)

References

Details

Attachments

(1 file)

As pointed out in bug 1337070, this test heap-allocates a single GCPtr.  We require GCPtr to be a member of class with GC managed lifetime - either a GC thing or a UniquePtr with GCManagedDeletePolicy delete policy.

Giving GCPtr itself a policy of GCManagedDeletePolicy has become problematic as this now requires a way of getting the zone from the pointer, and also never happens in practice.

The test should be updated to use GCPtrs in a more standard way, e.g. by embedding them in a suitable class.
This puts the pointer wrappers in a struct and gives the GCPtr version the delete policy it requires.
Attachment #8834511 - Flags: review?(bhackett1024)
Attachment #8834511 - Flags: review?(bhackett1024) → review+
Pushed by jcoppeard@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/a04acd9bb5d2
Fix testGCHeapPostBarriers jsapi test to have more standard API use r=bhackett
https://hg.mozilla.org/mozilla-central/rev/a04acd9bb5d2
Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla54
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: