Closed
Bug 765976
Opened 13 years ago
Closed 13 years ago
Simplify CompileFunctionBody's control flow
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla16
People
(Reporter: n.nethercote, Assigned: n.nethercote)
Details
(Whiteboard: [js:t])
Attachments
(1 file)
3.94 KB,
patch
|
sfink
:
review+
|
Details | Diff | Splinter Review |
CompileFunctionBody()'s second half is oddly keen to avoid return
statements. By using them, this patch reduces the nesting greatly and makes
the function more readable and more like CompileScript() (and most other
SpiderMonkey code).
![]() |
Assignee | |
Comment 1•13 years ago
|
||
Attachment #634241 -
Flags: review?(sphink)
![]() |
Assignee | |
Comment 2•13 years ago
|
||
Hey, |hg bzexport| actually works! Nice.
Status: NEW → ASSIGNED
Summary: Simplify CompileFunctionBody's control flow. → Simplify CompileFunctionBody's control flow
Whiteboard: [js:t]
![]() |
Assignee | |
Comment 3•13 years ago
|
||
BTW, I removed the "/* FoldConstants reported the error already. */" comment because AFAICT it's not true -- FoldConstants() doesn't report any errors.
Comment 4•13 years ago
|
||
Comment on attachment 634241 [details] [diff] [review]
Simplify CompileFunctionBody's control flow
Review of attachment 634241 [details] [diff] [review]:
-----------------------------------------------------------------
Yes, yes, a thousand times yes. The original was... well... WHY??!
Attachment #634241 -
Flags: review?(sphink) → review+
![]() |
Assignee | |
Comment 5•13 years ago
|
||
![]() |
||
Comment 6•13 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla16
You need to log in
before you can comment on or make changes to this bug.
Description
•