develooper Front page | perl.perl6.internals | Postings from July 2002

Re: Mutable vs immutable strings

Thread Previous | Thread Next
From:
John Porter
Date:
July 10, 2002 05:00
Subject:
Re: Mutable vs immutable strings
Message ID:
20020710120016.7567.qmail@web10802.mail.yahoo.com

"Clark C . Evans" wrote:
> So, I propose that Parrot supports both of these attitudes
> of reasoning by using a flag.   Initially, all strings
> are 'mutable'.

I concur with Clark.  What he's proposing is (it seems to me)
nothing more than a "read-only" flag, and that's as 
immutable as a variable needs to get.

However, I'm concerned about the performance impact of such a thing.
Perhaps a better approach would be to swap out the mutator methods
with code that throws.

-- 
John Douglas Porter


__________________________________________________
Do You Yahoo!?
Sign up for SBC Yahoo! Dial - First Month Free
http://sbc.yahoo.com

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