July 30, 2012 [Issue 3960] Unused local variables not reported | ||||
---|---|---|---|---|
| ||||
Posted in reply to bearophile_hugs@eml.cc | http://d.puremagic.com/issues/show_bug.cgi?id=3960 rswhite4@googlemail.com changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |rswhite4@googlemail.com --- Comment #30 from rswhite4@googlemail.com 2012-07-30 10:26:03 PDT --- I wrote a short programm which detect and list unused variables. I'm sure it isn't perfect but it passed most of my test cases and IMO something like this should be integrated into the D compiler. Maybe automatically if you use the -w or -wi compiler flag switch. Code: http://dpaste.dzfl.pl/c5f1d2ba Some of my testcases: http://dpaste.dzfl.pl/f74da85e -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
July 30, 2012 [Issue 3960] Unused local variables not reported | ||||
---|---|---|---|---|
| ||||
Posted in reply to bearophile_hugs@eml.cc | http://d.puremagic.com/issues/show_bug.cgi?id=3960 --- Comment #31 from bearophile_hugs@eml.cc 2012-07-30 10:38:23 PDT --- (In reply to comment #30) > Code: http://dpaste.dzfl.pl/c5f1d2ba > Some of my testcases: http://dpaste.dzfl.pl/f74da85e Paste sites eventually lose their content. That's why I have said to *attach* your stuff in Bugzilla. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
July 30, 2012 [Issue 3960] Unused local variables not reported | ||||
---|---|---|---|---|
| ||||
Posted in reply to bearophile_hugs@eml.cc | http://d.puremagic.com/issues/show_bug.cgi?id=3960 rswhite4@googlemail.com changed: What |Removed |Added ---------------------------------------------------------------------------- AssignedTo|nobody@puremagic.com |rswhite4@googlemail.com --- Comment #32 from rswhite4@googlemail.com 2012-07-30 12:07:53 PDT --- Created an attachment (id=1128) Unused variables detector code Forget to upload the code of my unused variables detector. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
August 23, 2012 [Issue 3960] Unused local variables not reported | ||||
---|---|---|---|---|
| ||||
Posted in reply to bearophile_hugs@eml.cc | http://d.puremagic.com/issues/show_bug.cgi?id=3960 Stewart Gordon <smjg@iname.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #1128|application/octet-stream |text/plain mime type| | -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
October 21, 2012 [Issue 3960] Unused local variables not reported | ||||
---|---|---|---|---|
| ||||
Posted in reply to bearophile_hugs@eml.cc | http://d.puremagic.com/issues/show_bug.cgi?id=3960 --- Comment #33 from bearophile_hugs@eml.cc 2012-10-21 04:39:22 PDT --- A related warning is for "unused local alias". A bug in GCC, libstdc++/33084, in <valarrray> function with this body: typedef _BinClos<_Name, _Constant, _ValArray, _Tp, _Tp> _Closure; typedef typename __fun<_Name, _Tp>::result_type _Rt; return _Expr<_Closure, _Tp>(_Closure(__t, __v)); There is a typo: _Rt -> _Tp In GCC 4.7, the -Wunused-local-typedefs warning detects such sort of suspect "unused" typedef. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation