[32149] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3414 Volume: 11

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jun 14 14:14:30 2011

Date: Tue, 14 Jun 2011 11:14:16 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Tue, 14 Jun 2011     Volume: 11 Number: 3414

Today's topics:
        How initialize an array to 0's? gamo@telecable.es
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <tzz@lifelogs.com>
    Re: How initialize an array to 0's? <NoSpamPleaseButThisIsValid3@gmx.net>
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <willem@toad.stack.nl>
    Re: How initialize an array to 0's? <tzz@lifelogs.com>
    Re: How initialize an array to 0's? <sherm.pendley@gmail.com>
    Re: How initialize an array to 0's? <tzz@lifelogs.com>
    Re: How initialize an array to 0's? <tzz@lifelogs.com>
    Re: How initialize an array to 0's? <uri@StemSystems.com>
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <sherm.pendley@gmail.com>
    Re: How initialize an array to 0's? <tzz@lifelogs.com>
    Re: How initialize an array to 0's? <ralph@happydays.com>
    Re: How initialize an array to 0's? <kkeller-usenet@wombat.san-francisco.ca.us>
    Re: Scherz am Rande <sherm.pendley@gmail.com>
    Re: Scherz am Rande <rweikusat@mssgmbh.com>
    Re: Scherz am Rande <sherm.pendley@gmail.com>
    Re: Scherz am Rande <rweikusat@mssgmbh.com>
    Re: Scherz am Rande <kkeller-usenet@wombat.san-francisco.ca.us>
    Re: Scherz am Rande <tzz@lifelogs.com>
    Re: Scherz am Rande <cwilbur@chromatico.net>
    Re: Scherz am Rande <cwilbur@chromatico.net>
    Re: Scherz am Rande <sherm.pendley@gmail.com>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 14 Jun 2011 17:02:37 +0100
From: gamo@telecable.es
Subject: How initialize an array to 0's?
Message-Id: <4df7780d$1@news.x-privat.org>


I have the following correct sentence 

$flagi[1..$jornadas][1..$partidos] = 0;

that doesn't do anything useful.

What is the proper and modern mode to do the thing?

Thanks




------------------------------

Date: Tue, 14 Jun 2011 11:50:29 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <7111f$4df78346$ce534406$14184@news.eurofeeds.com>

Do you really mean to have a 2d array?
Anyway, use slices. Plus maybe some perl-ish tricks to quickly generate 
the list of 0s.
In the 1d case:
     #be careful, you probably want to start indexing at 0, not 1
     #leaving it your way for now
     @flagi[1..$jornadas]=split(/\s/,"0 "x$partidos);
If you really meant 2d then:
     @flagi;
     $flagi[$jornadas]=undef;#the first dimension is grown to have 
$jornados+1 elements
     #again, you probably want indices from 0 to $jornados-1.
     #but maybe you don't for some reason? I'll leave your way here too.
     map {[]} @flagi;
     foreach my $row (@flagi){
         @{$row}=split(/\s/,"0 "x$partidos);
     }
This code is untested but should be more  or less correct.
One more time, be careful with your indices! perl starts indexing at 0, 
not 1.


On 6/14/2011 12:02 PM, gamo@telecable.es wrote:
> I have the following correct sentence
>
> $flagi[1..$jornadas][1..$partidos] = 0;
>
> that doesn't do anything useful.
>
> What is the proper and modern mode to do the thing?
>
> Thanks
>
>



------------------------------

Date: Tue, 14 Jun 2011 11:58:42 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <482fd$4df78532$ce534406$14184@news.eurofeeds.com>

Whoops, in that 1d case this line
> @flagi[1..$jornadas]=split(/\s/,"0 "x$partidos);
should instead read
     @flagi[1..$jornadas]=split(/\s/,"0 "x$jornadas);
So, the number of elements is correct


------------------------------

Date: Tue, 14 Jun 2011 11:06:55 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <878vt4wg68.fsf@lifelogs.com>

On Tue, 14 Jun 2011 11:58:42 -0400 Ralph Malph <ralph@happydays.com> wrote: 

RM> Whoops, in that 1d case this line
>> @flagi[1..$jornadas]=split(/\s/,"0 "x$partidos);
RM> should instead read
RM>     @flagi[1..$jornadas]=split(/\s/,"0 "x$jornadas);
RM> So, the number of elements is correct

Are you aware of what (0) x 20 does?  split() is completely unnecessary.

Ted


------------------------------

Date: Tue, 14 Jun 2011 18:16:57 +0200
From: Wolf Behrenhoff <NoSpamPleaseButThisIsValid3@gmx.net>
Subject: Re: How initialize an array to 0's?
Message-Id: <4df7897a$0$6577$9b4e6d93@newsspool3.arcor-online.net>

On 14.06.2011 17:58, Ralph Malph wrote:
> Whoops, in that 1d case this line
>> @flagi[1..$jornadas]=split(/\s/,"0 "x$partidos);
> should instead read
>      @flagi[1..$jornadas]=split(/\s/,"0 "x$jornadas);
> So, the number of elements is correct

What is this?

First you create a string, then you split it again? Further, you assign
the value "0", not 0.

better use:
  @array[1..$n] = (0) x $n;

For 2d arrays (= an array of array references), you will need to loop
over the first array and run the above command for every array element.

Wolf


------------------------------

Date: Tue, 14 Jun 2011 12:23:27 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <6f99e$4df78aff$ce534406$11611@news.eurofeeds.com>

No, actually, I didn't!
Has this always been in the language or is it a new-ish feature?
I didn't know the x operator worked with lists.
Cool stuff. Thanks.

On 6/14/2011 12:06 PM, Ted Zlatanov wrote:
> (0) x 20



------------------------------

Date: Tue, 14 Jun 2011 16:31:46 +0000 (UTC)
From: Willem <willem@toad.stack.nl>
Subject: Re: How initialize an array to 0's?
Message-Id: <slrnivf37i.25bs.willem@toad.stack.nl>

Wolf Behrenhoff wrote:
) On 14.06.2011 17:58, Ralph Malph wrote:
)> Whoops, in that 1d case this line
)>> @flagi[1..$jornadas]=split(/\s/,"0 "x$partidos);
)> should instead read
)>      @flagi[1..$jornadas]=split(/\s/,"0 "x$jornadas);
)> So, the number of elements is correct
)
) What is this?
)
) First you create a string, then you split it again? Further, you assign
) the value "0", not 0.
)
) better use:
)   @array[1..$n] = (0) x $n;
)
) For 2d arrays (= an array of array references), you will need to loop
) over the first array and run the above command for every array element.

Doesn't:
  @array = ([(0) x $n]) x $n;
work ?


(Yes, I know it doesn't work, the interesting bit is in why it doesn't.)



SaSW, Willem
-- 
Disclaimer: I am in no way responsible for any of the statements
            made in the above text. For all I know I might be
            drugged or something..
            No I'm not paranoid. You all think I'm paranoid, don't you !
#EOT


------------------------------

Date: Tue, 14 Jun 2011 11:34:41 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <87pqmgv0bi.fsf@lifelogs.com>

On Tue, 14 Jun 2011 12:23:27 -0400 Ralph Malph <ralph@happydays.com> wrote: 

RM> On 6/14/2011 12:06 PM, Ted Zlatanov wrote:
>> (0) x 20

RM> No, actually, I didn't!
RM> Has this always been in the language or is it a new-ish feature?

At least since 5.005, probably earlier too.

Ted


------------------------------

Date: Tue, 14 Jun 2011 12:41:30 -0400
From: Sherm Pendley <sherm.pendley@gmail.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <m2hb7sqsat.fsf@sherm.shermpendley.com>

Ralph Malph <ralph@happydays.com> writes:

> Has this always been in the language or is it a new-ish feature?
> I didn't know the x operator worked with lists.

Maybe if you *read* the FAQs instead of mocking them, you'd learn more
about this stuff...

sherm--


------------------------------

Date: Tue, 14 Jun 2011 11:42:31 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <87lix4uzyg.fsf@lifelogs.com>

On Tue, 14 Jun 2011 16:31:46 +0000 (UTC) Willem <willem@toad.stack.nl> wrote: 

W> Doesn't:
W>   @array = ([(0) x $n]) x $n;
W> work ?

W> (Yes, I know it doesn't work, the interesting bit is in why it doesn't.)

It copies the array reference 20 times, which is probably not wanted.

Here's what I would use for a 20x20:

@array = map {[(0) x 20]} (1..20);

Or, for triangular fun:

@array = map {[(0) x $_]} (1..20);

Ted


------------------------------

Date: Tue, 14 Jun 2011 11:46:34 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <87hb7suzrp.fsf@lifelogs.com>

On Tue, 14 Jun 2011 12:41:30 -0400 Sherm Pendley <sherm.pendley@gmail.com> wrote: 

SP> Ralph Malph <ralph@happydays.com> writes:
>> Has this always been in the language or is it a new-ish feature?
>> I didn't know the x operator worked with lists.

SP> Maybe if you *read* the FAQs instead of mocking them, you'd learn more
SP> about this stuff...

To be fair, he mostly mocks the posting guidelines ;)

Ted


------------------------------

Date: Tue, 14 Jun 2011 12:50:18 -0400
From: "Uri Guttman" <uri@StemSystems.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <87y614pdbp.fsf@quad.sysarch.com>

>>>>> "RM" == Ralph Malph <ralph@happydays.com> writes:

  RM> No, actually, I didn't!
  RM> Has this always been in the language or is it a new-ish feature?
  RM> I didn't know the x operator worked with lists.
  RM> Cool stuff. Thanks.

and yet you flame and troll about everyone else here and the
guidelines. just more proof of your uselessness here. go away. you make
moronzilla look good.

uri

-- 
Uri Guttman  ------  uri@stemsystems.com  --------  http://www.sysarch.com --
-----  Perl Code Review , Architecture, Development, Training, Support ------
---------  Gourmet Hot Cocoa Mix  ----  http://bestfriendscocoa.com ---------


------------------------------

Date: Tue, 14 Jun 2011 12:58:03 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <c1ef3$4df7931b$ce534406$16841@news.eurofeeds.com>

What is a "moronzilla" ?
I think you are not a very nice person.
Perhaps it is because you weigh 400 pounds and reek of faeces.
Anyway, my way seems to work although perhaps it isn't the most efficient.
At least I offered a working solution instead of whinging and making 
weird references.

On 6/14/2011 12:50 PM, Uri Guttman wrote:
>>>>>> "RM" == Ralph Malph<ralph@happydays.com>  writes:
>
>    RM>  No, actually, I didn't!
>    RM>  Has this always been in the language or is it a new-ish feature?
>    RM>  I didn't know the x operator worked with lists.
>    RM>  Cool stuff. Thanks.
>
> and yet you flame and troll about everyone else here and the
> guidelines. just more proof of your uselessness here. go away. you make
> moronzilla look good.
>
> uri
>



------------------------------

Date: Tue, 14 Jun 2011 13:03:27 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <7322d$4df7945e$ce534406$19027@news.eurofeeds.com>

Feel free to point out where this is covered in the faq.
http://faq.perl.org/

On 6/14/2011 12:41 PM, Sherm Pendley wrote:
> Ralph Malph<ralph@happydays.com>  writes:
>
>> Has this always been in the language or is it a new-ish feature?
>> I didn't know the x operator worked with lists.
>
> Maybe if you *read* the FAQs instead of mocking them, you'd learn more
> about this stuff...
>
> sherm--



------------------------------

Date: Tue, 14 Jun 2011 13:16:40 -0400
From: Sherm Pendley <sherm.pendley@gmail.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <m2d3igqqo7.fsf@sherm.shermpendley.com>

Ted Zlatanov <tzz@lifelogs.com> writes:

> On Tue, 14 Jun 2011 12:41:30 -0400 Sherm Pendley <sherm.pendley@gmail.com> wrote: 
>
> SP> Ralph Malph <ralph@happydays.com> writes:
>>> Has this always been in the language or is it a new-ish feature?
>>> I didn't know the x operator worked with lists.
>
> SP> Maybe if you *read* the FAQs instead of mocking them, you'd learn more
> SP> about this stuff...
>
> To be fair, he mostly mocks the posting guidelines ;)

True! I did miss the mark a bit. Just too tempting to resist though... :-)

sherm--


------------------------------

Date: Tue, 14 Jun 2011 12:25:09 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <87tybstjey.fsf@lifelogs.com>

On Tue, 14 Jun 2011 12:58:03 -0400 Ralph Malph <ralph@happydays.com> wrote: 

RM> What is a "moronzilla" ?

See http://www.perlmonks.org/?node_id=404291 but really, if you didn't
live through it, it's hard to explain.

Ted


------------------------------

Date: Tue, 14 Jun 2011 13:50:58 -0400
From: Ralph Malph <ralph@happydays.com>
Subject: Re: How initialize an array to 0's?
Message-Id: <d1ef3$4df79f83$ce534406$12728@news.eurofeeds.com>

Ah! I see! I did Google Groups search for purl gurl and got all sorts
of bizarre stuff.
Thanks for the tip.

On 6/14/2011 1:25 PM, Ted Zlatanov wrote:
> On Tue, 14 Jun 2011 12:58:03 -0400 Ralph Malph<ralph@happydays.com>  wrote:
>
> RM>  What is a "moronzilla" ?
>
> See http://www.perlmonks.org/?node_id=404291 but really, if you didn't
> live through it, it's hard to explain.
>
> Ted



------------------------------

Date: Tue, 14 Jun 2011 10:58:07 -0700
From: Keith Keller <kkeller-usenet@wombat.san-francisco.ca.us>
Subject: Re: How initialize an array to 0's?
Message-Id: <f2kkc8xk44.ln2@goaway.wombat.san-francisco.ca.us>

On 2011-06-14, gamo@telecable.es <gamo@telecable.es> wrote:
>
> I have the following correct sentence 
>
> $flagi[1..$jornadas][1..$partidos] = 0;
>
> that doesn't do anything useful.
>
> What is the proper and modern mode to do the thing?

Do you have to initialize the elements to 0?  Because Perl will
convert undef to 0 in a numeric expression, so that e.g.

$myvar=4 + $flagi[2][4];

will put 4 into $myvar.  (If you are using warnings, you will get one;
you can use "no warnings 'uninitialized';" in that block if you want to
suppress that warning.)

--keith

-- 
kkeller-usenet@wombat.san-francisco.ca.us
(try just my userid to email me)
AOLSFAQ=http://www.therockgarden.ca/aolsfaq.txt
see X- headers for PGP signature information



------------------------------

Date: Tue, 14 Jun 2011 07:29:40 -0400
From: Sherm Pendley <sherm.pendley@gmail.com>
Subject: Re: Scherz am Rande
Message-Id: <m2k4coslaz.fsf@sherm.shermpendley.com>

Rainer Weikusat <rweikusat@mssgmbh.com> writes:

> Ted Zlatanov <tzz@lifelogs.com> writes:
>>
>> Sure, but it also helps to set up the environment correctly.  *Your*
>> problem is that you have code in production that should not have passed
>> QA,
>
> And your problem is that your overly vivid imagination causes you to
> see things which don't exist and to assume things which don't make
> sense.

What are you talking about? You said it yourself - you have code in
production that emits warnings. That's a failure in QA. The issues that
are pointed to by the warnings should have been fixed before the code
was released, and it's (part of) QAs job to make sure they were.

And no, silencing the warnings by choosing not to "use warnings" does
not fix the problems. That's what Uri was on about - *good* programmers
proactively look for problems in their code, using every tool available,
and then *fix the problems*.

sherm--


------------------------------

Date: Tue, 14 Jun 2011 13:17:43 +0100
From: Rainer Weikusat <rweikusat@mssgmbh.com>
Subject: Re: Scherz am Rande
Message-Id: <878vt4d2u0.fsf@sapphire.mobileactivedefense.com>

Sherm Pendley <sherm.pendley@gmail.com> writes:
> Rainer Weikusat <rweikusat@mssgmbh.com> writes:
>
>> Ted Zlatanov <tzz@lifelogs.com> writes:
>>>
>>> Sure, but it also helps to set up the environment correctly.  *Your*
>>> problem is that you have code in production that should not have passed
>>> QA,
>>
>> And your problem is that your overly vivid imagination causes you to
>> see things which don't exist and to assume things which don't make
>> sense.
>
> What are you talking about? You said it yourself - you have code in
> production that emits warnings.

I wrote nothing of this sort but that I got a "Help me!" e-mail from
some contractor who ran into a mysterious problem during
development. Actually, in my reply to Ted, I even additionally wrote: "My
problem will likely be that this code will be shipped to someone
soon". This means that you assertion above is in direct contradiction
to a truth which can be easily checked by anyone with access to a
USENET posting archive.



------------------------------

Date: Tue, 14 Jun 2011 08:30:40 -0400
From: Sherm Pendley <sherm.pendley@gmail.com>
Subject: Re: Scherz am Rande
Message-Id: <m2fwncbnnz.fsf@sherm.shermpendley.com>

Rainer Weikusat <rweikusat@mssgmbh.com> writes:

> Sherm Pendley <sherm.pendley@gmail.com> writes:
>> Rainer Weikusat <rweikusat@mssgmbh.com> writes:
>>
>>> Ted Zlatanov <tzz@lifelogs.com> writes:
>>>>
>>>> Sure, but it also helps to set up the environment correctly.  *Your*
>>>> problem is that you have code in production that should not have passed
>>>> QA,
>>>
>>> And your problem is that your overly vivid imagination causes you to
>>> see things which don't exist and to assume things which don't make
>>> sense.
>>
>> What are you talking about? You said it yourself - you have code in
>> production that emits warnings.
>
> I wrote nothing of this sort but that I got a "Help me!" e-mail from
> some contractor who ran into a mysterious problem during
> development. Actually, in my reply to Ted, I even additionally wrote: "My
> problem will likely be that this code will be shipped to someone
> soon". This means that you assertion above is in direct contradiction
> to a truth which can be easily checked by anyone with access to a
> USENET posting archive.

In other words, you're a troll who would rather split hairs about who
said what, than address the real problem of your stance concerning the
warnings pragma.

Buh bye then - won't be reading any more of your drivel.

*plonk*

sherm--


------------------------------

Date: Tue, 14 Jun 2011 13:49:25 +0100
From: Rainer Weikusat <rweikusat@mssgmbh.com>
Subject: Re: Scherz am Rande
Message-Id: <874o3sd1d6.fsf@sapphire.mobileactivedefense.com>

Sherm Pendley <sherm.pendley@gmail.com> writes:
> Rainer Weikusat <rweikusat@mssgmbh.com> writes:
>
>> Sherm Pendley <sherm.pendley@gmail.com> writes:
>>> Rainer Weikusat <rweikusat@mssgmbh.com> writes:
>>>
>>>> Ted Zlatanov <tzz@lifelogs.com> writes:
>>>>>
>>>>> Sure, but it also helps to set up the environment correctly.  *Your*
>>>>> problem is that you have code in production that should not have passed
>>>>> QA,
>>>>
>>>> And your problem is that your overly vivid imagination causes you to
>>>> see things which don't exist and to assume things which don't make
>>>> sense.
>>>
>>> What are you talking about? You said it yourself - you have code in
>>> production that emits warnings.
>>
>> I wrote nothing of this sort but that I got a "Help me!" e-mail from
>> some contractor who ran into a mysterious problem during
>> development. Actually, in my reply to Ted, I even additionally wrote: "My
>> problem will likely be that this code will be shipped to someone
>> soon". This means that you assertion above is in direct contradiction
>> to a truth which can be easily checked by anyone with access to a
>> USENET posting archive.
>
> In other words, you're a troll who would rather split hairs about who
> said what, than address the real problem of your stance concerning the
> warnings pragma.

I consider 'sticking to the truth', especially, sticking to the truth
in statements about other people, a virtue ...

> Buh bye then - won't be reading any more of your drivel.

 ... and I'm also convinced that 'good programmers' should have an
interest in discussing advantages and disadvantages of specific
development methods. That is, they shouldn't start spouting random
abuse and disingenious lies (see above) when being confronted with
opinions they don't share.




------------------------------

Date: Tue, 14 Jun 2011 07:39:46 -0700
From: Keith Keller <kkeller-usenet@wombat.san-francisco.ca.us>
Subject: Re: Scherz am Rande
Message-Id: <ie8kc8xuk1.ln2@goaway.wombat.san-francisco.ca.us>

On 2011-06-14, Rainer Weikusat <rweikusat@mssgmbh.com> wrote:
>
> In this particular case, what you refer to as 'accepted coding
> standard' caused warnings to essentially go by unnoticed (bad)

No, PEBKAC caused those warnings to go unnoticed.

--keith


-- 
kkeller-usenet@wombat.san-francisco.ca.us
(try just my userid to email me)
AOLSFAQ=http://www.therockgarden.ca/aolsfaq.txt
see X- headers for PGP signature information



------------------------------

Date: Tue, 14 Jun 2011 10:24:56 -0500
From: Ted Zlatanov <tzz@lifelogs.com>
Subject: Re: Scherz am Rande
Message-Id: <87oc20wi47.fsf@lifelogs.com>

On Tue, 14 Jun 2011 09:31:30 +0100 Rainer Weikusat <rweikusat@mssgmbh.com> wrote: 

RW> Ted Zlatanov <tzz@lifelogs.com> writes:

>> That's annoying.  I'd say that's the heart of *his* problem: not
>> understanding the environment and ignoring warning messages.
>> 
>> But that's not *your* problem.

RW> Exactly. My problem will likely be that this code is going to ship to
RW> someone soon and what other 'unexpected features' it might develop
RW> there remains to be determined. But this is actually besides the
RW> point.

Well, your e-mail complained about the two problems (the contractor's
carelessness and your obligation to fix it), so I think addressing the
latter is quite to the point.  In fact, it is the main point; bad code
will always be written, but complaining that it broke a server indicates
a misunderstanding of what needs to fixed.

RW> What would have helped here is an actual understanding of this
RW> facility, the uses it can be put to and also, its limitations. But "do
RW> as I say or I'll HURT you" doesn't help people to understand.

Sure.  I don't think anyone is arguing that.  But it's not very relevant
to the things you complained about.

RW> And your problem is that your overly vivid imagination causes you to
RW> see things which don't exist and to assume things which don't make
RW> sense. But that's also besides the point.

I accept your apology.  Gesundheit.

Ted


------------------------------

Date: Tue, 14 Jun 2011 12:03:08 -0400
From: Charlton Wilbur <cwilbur@chromatico.net>
Subject: Re: Scherz am Rande
Message-Id: <86lix4tn7n.fsf@mithril.chromatico.net>

>>>>> "RW" == Rainer Weikusat <rweikusat@mssgmbh.com> writes:

    RW> Exactly. My problem will likely be that this code is going to
    RW> ship to someone soon and what other 'unexpected features' it
    RW> might develop there remains to be determined. But this is
    RW> actually besides the point.

Right.  So he wrote code that generates warnings, and in your entire
development process, nobody noticed the warnings.  

The problem is not the coding standard; the problem is that your
development and testing process is so shoddy that the code either never
got tested in a duplicate of your production environment or that nobody
was paying enough attention to the test to notice the warnings.

Blaming it on the coding standard because the coding standard *revealed*
the errors is asinine and ass-backwards.

Charlton



-- 
Charlton Wilbur
cwilbur@chromatico.net


------------------------------

Date: Tue, 14 Jun 2011 12:08:54 -0400
From: Charlton Wilbur <cwilbur@chromatico.net>
Subject: Re: Scherz am Rande
Message-Id: <86hb7stmy1.fsf@mithril.chromatico.net>

>>>>> "RW" == Rainer Weikusat <rweikusat@mssgmbh.com> writes:

    RW> ... and I'm also convinced that 'good programmers' should have
    RW> an interest in discussing advantages and disadvantages of
    RW> specific development methods. 

Good programmers do.  That, in fact, is what we are doing.

The problem you are complaining about, however, is that you have a flaw
in your software testing and QA processes.  You have misdiagnosed it as
a flaw in Perl coding best practices, and you are attempting to
criticize the coding practice that revealed the flaw in your practice as
if the coding practice is itself the problem.

If you want to *productively* discuss the advantages and disadvantages
of strictures and warnings, you will need to find other material.  If
you want to natter on like a kook, do carry on, but you'll find your
audience diminishing rapidly.

Charlton



-- 
Charlton Wilbur
cwilbur@chromatico.net


------------------------------

Date: Tue, 14 Jun 2011 12:18:34 -0400
From: Sherm Pendley <sherm.pendley@gmail.com>
Subject: Re: Scherz am Rande
Message-Id: <m2lix4qtd1.fsf@sherm.shermpendley.com>

Charlton Wilbur <cwilbur@chromatico.net> writes:

> Blaming it on the coding standard because the coding standard *revealed*
> the errors is asinine and ass-backwards.

Exactly!

Blaming the tool for the errors it reports in your code is like blaming
the house inspector for the termites he finds in your basement.

sherm--


------------------------------

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
Message-Id: <null>


Administrivia:

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

Back issues are available via anonymous ftp from
ftp://cil-www.oce.orst.edu/pub/perl/old-digests. 

#For other requests pertaining to the digest, send mail to
#perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
#sending perl questions to the -request address, I don't have time to
#answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V11 Issue 3414
***************************************


home help back first fref pref prev next nref lref last post