develooper Front page | perl.perl5.porters | Postings from April 2007

Re: [PATCH] madprop about forced words

Thread Previous | Thread Next
From:
Nicholas Clark
Date:
April 25, 2007 17:44
Subject:
Re: [PATCH] madprop about forced words
Message ID:
20070425161334.GA78146@plum.flirble.org
On Fri, Apr 20, 2007 at 01:56:38PM +0200, Rafael Garcia-Suarez wrote:
> On 19/04/07, Gerard Goossen <gerard@tty.nl> wrote:

> >We are running a bit out of letter so I was planning to refactor the
> >madprop to use strings instead of letters (i.e. change
> ><char mad_key> to <const char* mad_key> and <curmad('X', ...)>
> >to <cumad("random", ...)>, any objections?
> 
> char* means allocation and deallocation problems. If you need more,
> why don't you use a char[2] instead ? (which will be more
> space-efficient as well)

Although more complex to compare

A possible alternative is to continue using a char, but #define two character
mnemonics that map to it.

Nicholas Clark

Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About