Closed
Bug 824879
Opened 12 years ago
Closed 12 years ago
Avoid -Wconstant-conversion warnings in vm/RegExpObject.cpp.
Categories
(Core :: JavaScript Engine, defect)
Core
JavaScript Engine
Tracking
()
RESOLVED
FIXED
mozilla20
People
(Reporter: n.nethercote, Assigned: n.nethercote)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
947 bytes,
patch
|
sstangl
:
review+
|
Details | Diff | Splinter Review |
Clang 3.2 warns:
js/src/vm/RegExpObject.cpp:125:27 [-Wconstant-conversion] implicit conversion
from 'size_t' (aka 'unsigned long') to 'int' changes value from 1844674
4073709551615 to -1
js/src/vm/RegExpObject.cpp:126:27 [-Wconstant-conversion] implicit conversion
from 'size_t' (aka 'unsigned long') to 'int' changes value from 1844674
4073709551615 to -1
Assignee | ||
Comment 1•12 years ago
|
||
MatchPair.{start,limit} are both |int|, so the current code converts -1 from
|int| to |size_t| and back to |int|. This patch just gets rid of the |size_t|
cast.
Attachment #695904 -
Flags: review?(sstangl)
Assignee | ||
Updated•12 years ago
|
Blocks: buildwarning
Comment 2•12 years ago
|
||
Comment on attachment 695904 [details] [diff] [review]
Avoid -Wconstant-conversion warnings in vm/RegExpObject.cpp.
Review of attachment 695904 [details] [diff] [review]:
-----------------------------------------------------------------
This was supposed to be fixed in Bug 820124, but it's not sticking. It's fine to fix it separately.
Attachment #695904 -
Flags: review?(sstangl) → review+
Assignee | ||
Comment 3•12 years ago
|
||
Comment 4•12 years ago
|
||
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla20
You need to log in
before you can comment on or make changes to this bug.
Description
•