http://codereview.appspot.com/4609047/diff/11001/src/pkg/syscall/mksyscall.pl File src/pkg/syscall/mksyscall.pl (right): http://codereview.appspot.com/4609047/diff/11001/src/pkg/syscall/mksyscall.pl#newcode31 src/pkg/syscall/mksyscall.pl:31: if(@ARGV) { You're doing this to work around your ...
13 years, 9 months ago
(2011-06-15 17:43:07 UTC)
#4
http://codereview.appspot.com/4609047/diff/11001/src/pkg/syscall/mksyscall.pl
File src/pkg/syscall/mksyscall.pl (right):
http://codereview.appspot.com/4609047/diff/11001/src/pkg/syscall/mksyscall.pl...
src/pkg/syscall/mksyscall.pl:31: if(@ARGV) {
You're doing this to work around your "use warnings" addition complaining about
"Use of uninitialized value $ARGV[0]" below, yet you still shift @ARGV (on lines
34, 37, 31, 45) and proceed to access $ARGV[0] which may then be uninitialized.
(on lines 39, 43, 48)
So this doesn't go far enough.
I think you should just undo this part of the change and remove "use warnings",
else just use the standard library module Getopt::Long and remove all this code.
*shrug*
Just remove all the "use warnings" line and remove the line: if(@ARGV) { and unindent ...
13 years, 9 months ago
(2011-06-16 00:23:14 UTC)
#6
Just remove all the "use warnings" line and remove the line:
if(@ARGV) {
and unindent it all, like it was before.
Just keep the "use strict" lines and the "my" additions.
On Wed, Jun 15, 2011 at 5:14 PM, mattn <mattn.jp@gmail.com> wrote:
> Russ, Do you mean that 'back the code of manipulating @ARGV and remove "use
> warnings"'?
>
>
On 2011/06/16 00:23:14, bradfitz wrote: > Just remove all the "use warnings" line and remove ...
13 years, 9 months ago
(2011-06-16 00:26:47 UTC)
#7
On 2011/06/16 00:23:14, bradfitz wrote:
> Just remove all the "use warnings" line and remove the line:
>
> if(@ARGV) {
>
> and unindent it all, like it was before.
>
> Just keep the "use strict" lines and the "my" additions.
>
> On Wed, Jun 15, 2011 at 5:14 PM, mattn <mailto:mattn.jp@gmail.com> wrote:
>
> > Russ, Do you mean that 'back the code of manipulating @ARGV and remove "use
> > warnings"'?
> >
> >
Done
LGTM On Wed, Jun 15, 2011 at 5:26 PM, <mattn.jp@gmail.com> wrote: > On 2011/06/16 00:23:14, ...
13 years, 9 months ago
(2011-06-16 00:36:00 UTC)
#8
LGTM
On Wed, Jun 15, 2011 at 5:26 PM, <mattn.jp@gmail.com> wrote:
> On 2011/06/16 00:23:14, bradfitz wrote:
>
>> Just remove all the "use warnings" line and remove the line:
>>
>
> if(@ARGV) {
>>
>
> and unindent it all, like it was before.
>>
>
> Just keep the "use strict" lines and the "my" additions.
>>
>
> On Wed, Jun 15, 2011 at 5:14 PM, mattn <mailto:mattn.jp@gmail.com>
>>
> wrote:
>
> > Russ, Do you mean that 'back the code of manipulating @ARGV and
>>
> remove "use
>
>> > warnings"'?
>> >
>> >
>>
>
> Done
>
>
>
http://codereview.appspot.com/**4609047/<http://codereview.appspot.com/4609047/>
>
Issue 4609047: code review 4609047: syscall: use strict in perl scripts
(Closed)
Created 13 years, 9 months ago by mattn
Modified 13 years, 9 months ago
Reviewers:
Base URL:
Comments: 1