Assertion parsing 'foo getter'

VERIFIED FIXED in mozilla1.8beta4

Status

()

Core
JavaScript Engine
P2
normal
VERIFIED FIXED
12 years ago
12 years ago

People

(Reporter: mrbkap, Assigned: brendan)

Tracking

({js1.5, verified1.8})

Trunk
mozilla1.8beta4
x86
Linux
js1.5, verified1.8
Points:
---
Bug Flags:
blocking1.8b4 +
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

12 years ago
I was playing around with getters and setters, and found that:
foo getter

Causes: Assertion failure: ts->lookahead == 0 || ON_CURRENT_LINE(ts,
CURRENT_TOKEN(ts).pos), at jsscan.c:1052

This is because getting and ungetting newline tokens leaves the scanner in an
inconsistent state (the EOL token ends up on the wrong line).
(Assignee)

Comment 1

12 years ago
Created attachment 194636 [details] [diff] [review]
fix the assertion

No need to complicate other code and tax release build runtime, let's just fix
the silly assertion.

/be
Attachment #194636 - Flags: review?(mrbkap)
Attachment #194636 - Flags: approval1.8b4+
(Assignee)

Comment 2

12 years ago
This bug concerns a bogus assertion, something in DEBUG builds only.  Fix
likewise affects only DEBUG builds, so it's good for branch and trunk.

/be
Flags: blocking1.8b4+
(Assignee)

Comment 3

12 years ago
Simplest testcase that botches the assert is just 'getter\n'.

/be
Assignee: general → brendan
Keywords: js1.5
Priority: -- → P2
Target Milestone: --- → mozilla1.8beta4
(Reporter)

Comment 4

12 years ago
Comment on attachment 194636 [details] [diff] [review]
fix the assertion

Sure. r=mrbkap
Attachment #194636 - Flags: review?(mrbkap) → review+
(Assignee)

Comment 5

12 years ago
Fixed, trunk and branch.

/be
Status: NEW → RESOLVED
Last Resolved: 12 years ago
Keywords: fixed1.8
Resolution: --- → FIXED

Comment 6

12 years ago
Checking in regress-306794.js;
/cvsroot/mozilla/js/tests/js1_5/Regress/regress-306794.js,v  <--  regress-306794.js
initial revision: 1.1
done

To test this you need to run a debug build an check stdout|err.
Flags: testcase+

Comment 7

12 years ago
verified fixed 1.8.x and trunk.
Status: RESOLVED → VERIFIED
Keywords: fixed1.8 → verified1.8
You need to log in before you can comment on or make changes to this bug.