Open Bug 164767 Opened 22 years ago Updated 2 years ago

Bad optimisation in ExprParser

Categories

(Core :: XSLT, defect)

defect

Tracking

()

People

(Reporter: sicking, Unassigned)

References

(Depends on 1 open bug)

Details

Attachments

(1 file)

The ExprParser optimises expressions like "---foo" into "-foo" which is nice.
However it should not optimise "--foo" into "foo" since that will have a
different value if "foo" can't be converted into a number and back without
loosing information. We can fix this either by adding a
ExprParser::createUnaryExpr or by converting "--foo" into "number(foo)"
Once we fix the parsing of function params, we could actually merge UnaryExpr and
number(). A little bit of footprint.
Depends on: 143291
QA Contact: keith → xslt
Someone filed a dupe of this recently, but I can't seem to find it. Anyhow, I wrote up this. Needs testing, and tests.

Attaching as to not lose it.
Assignee: peterv → jonas
Status: NEW → ASSIGNED
Attachment #505524 - Attachment description: Patch to fix. Nees test → Patch to fix. Needs test
Severity: normal → S3

The bug assignee is inactive on Bugzilla, so the assignee is being reset.

Assignee: jonas → nobody
Status: ASSIGNED → NEW
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: