Closed Bug 1590643 Opened 2 years ago Closed 2 years ago

Be more consistent about arena_id_t argument order

Categories

(Core :: JavaScript Engine, task, P3)

task

Tracking

()

RESOLVED FIXED
mozilla72
Tracking Status
firefox72 --- fixed

People

(Reporter: jandem, Assigned: jandem)

Details

Attachments

(1 file)

The code here looks a bit inconsistent: https://searchfox.org/mozilla-central/rev/8a63fc190b39ed6951abb4aef4a56487a43962bc/js/src/vm/StringType.cpp#460-464

I think this is because the arena argument to cx->pod_malloc is optional. We could avoid this if we added cx->pod_arena_malloc instead. That also makes the name more consistent with js_pod_arena_malloc.

Add separate pod_arena_* overloads and remove the optional arena_id_t arguments.

This makes both the naming and argument order more consistent with similar code
elsewhere (for example js_pod_arena_malloc, AllocPolicyBase::pod_arena_malloc).

Assignee: nobody → jdemooij
Status: NEW → ASSIGNED
Pushed by jdemooij@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/53abc22d3299
Be more consistent about arena_id_t arguments in MallocProvider.h. r=jwalden
Status: ASSIGNED → RESOLVED
Closed: 2 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla72
You need to log in before you can comment on or make changes to this bug.