jsscript.cpp:423:16: warning: variable ‘notes’ set but not used [-Wunused-but-set-variable]

RESOLVED FIXED in mozilla21

Status

()

defect
RESOLVED FIXED
7 years ago
7 years ago

People

(Reporter: dholbert, Assigned: dholbert)

Tracking

(Blocks 1 bug)

Trunk
mozilla21
x86_64
Linux
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment, 1 obsolete attachment)

Build warning:
{
js/src/jsscript.cpp:423:16: warning: variable ‘notes’ set but not used [-Wunused-but-set-variable]

I *think* the last usage of this variable was this code, for bug 571249:
> for (sn = notes; !SN_IS_TERMINATOR(sn); sn = SN_NEXT(sn))
which was removed here:
https://hg.mozilla.org/mozilla-central/diff/b35005673847/js/src/jsscript.cpp#l1.30

...though that was a long time ago, so maybe there was another more-recently-removed usage that I'm missing.
Assignee: general → dholbert
Status: NEW → ASSIGNED
Attachment #713583 - Flags: review?(n.nethercote)
sorry, that patch included some unrelated debugging code. reposting.
Posted patch fix v1aSplinter Review
Attachment #713583 - Attachment is obsolete: true
Attachment #713583 - Flags: review?(n.nethercote)
Attachment #713584 - Flags: review?(n.nethercote)
Attachment #713583 - Attachment description: fix v1 → fix v1 (w/ some accidental unrelated debugging code)
Comment on attachment 713584 [details] [diff] [review]
fix v1a

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

It was bug 679940.  Looks ok to me but I'll ask Till for review, since he did bug 679940, and this might suggest some additional cleanups.
Attachment #713584 - Flags: review?(tschneidereit)
Attachment #713584 - Flags: review?(n.nethercote)
Attachment #713584 - Flags: review+
Depends on: 679940
Comment on attachment 713584 [details] [diff] [review]
fix v1a

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

sorry about that, clang's usage warnings don't seem to be triggered by write-only usage. Or I'm just blind. Probably the latter, so take me not seeing more cleanup opportunities with a grain of salt.
Attachment #713584 - Flags: review?(tschneidereit) → review+
no worries / thanks!

(If there end up being more cleanup opportunities that we discover later, I'm sure we can deal with them in other bugs. In the meantime, this is the only GCC 4.7 build warning that I get for this file.)
https://hg.mozilla.org/mozilla-central/rev/e5694309feed
Status: ASSIGNED → RESOLVED
Closed: 7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla21
You need to log in before you can comment on or make changes to this bug.