Remove code to handle already assigned inferred name from BytecodeEmitter

RESOLVED FIXED in Firefox 61

Status

()

enhancement
P3
normal
RESOLVED FIXED
Last year
Last year

People

(Reporter: anba, Assigned: anba)

Tracking

Trunk
mozilla61
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(firefox61 fixed)

Details

Attachments

(1 attachment, 1 obsolete attachment)

https://searchfox.org/mozilla-central/rev/003262ae12ce937950ffb8d3b0fa520d1cc38bff/js/src/frontend/BytecodeEmitter.cpp#5493-5495

> // Single node can be emitted multiple times if it appears in
> // array destructuring default.  If function already has a name,
> // just return.


That comment and its corresponding code should be obsolete since bug 1322314.
Posted patch bug1448837.patch (obsolete) — Splinter Review
IIRC the check in BytecodeEmitter.cpp is no longer necessary because of the changes in bug 1322314. If that's correct we can also modify NameToFunctionName, now that it is only called in JSFunction.cpp, to take a HandleValue instead of a JSAtom* parameter which enables us to skip one call to ToAtom if |prefixKind != FunctionPrefixKind::None|.
Attachment #8962370 - Flags: review?(arai.unmht)
Comment on attachment 8962370 [details] [diff] [review]
bug1448837.patch

Review of attachment 8962370 [details] [diff] [review]:
-----------------------------------------------------------------

Thanks!
Attachment #8962370 - Flags: review?(arai.unmht) → review+
Priority: -- → P3
Updated to apply cleanly on inbound, carrying r+.
Attachment #8962370 - Attachment is obsolete: true
Attachment #8963102 - Flags: review+
Pushed by nbeleuzu@mozilla.com:
https://hg.mozilla.org/integration/mozilla-inbound/rev/4cd76f6e6217
Remove code to handle already set name now that parse nodes can no longer be emitted twice. r=arai
Keywords: checkin-needed
https://hg.mozilla.org/mozilla-central/rev/4cd76f6e6217
Status: ASSIGNED → RESOLVED
Closed: Last year
Resolution: --- → FIXED
Target Milestone: --- → mozilla61
You need to log in before you can comment on or make changes to this bug.