[bitc-dev] Vectors and mutability and bears (oh my)
Ben Kloosterman
bklooste at gmail.com
Thu Nov 4 18:34:43 PDT 2010
Ah I see my mistake , your just using the regions in the compiler not at run
time but knowing an object or static root is immutable is also very useful
to a GC or run time clone / threading routine. It is probably worth using a
bit in the type field for this for runtime objects ( provided your ok with
mutable xyz and immutable xyz being different types or masking it for type
comparisons) . Though for a GC immutable is immutable and all its
descendents.
Ben
>-----Original Message-----
>From: William Leslie [mailto:william.leslie.ttg at gmail.com]
>Sent: Friday, November 05, 2010 9:02 AM
>To: bklooste at gmail.com; Discussions about the BitC language
>Subject: Re: [bitc-dev] Vectors and mutability and bears (oh my)
>
>On 5 November 2010 11:19, Ben Kloosterman <bklooste at gmail.com> wrote:
>> Arent regions good for heap but problematic for static data ( and
>maybe
>> stack) ? tagging all static data would be expensive ( though static
>> immutable data is often const or readonly so maybe there is some way)
>
>Your region system can capture as much or as little information as you
>want it to. The region system for the compiler I'm working on at the
>moment has little interest in distinguishing different indexes of the
>same region with array type, for example. When it does, you can
>annotate the region of interest as needed, I use this for global,
>static lists of functions, for example.
>
>As far as dependent types go, it would be nice to specify *which*
>dependent types imply region types.
>
>--
>William Leslie
>No virus found in this incoming message.
>Checked by AVG - www.avg.com
>Version: 9.0.864 / Virus Database: 271.1.1/3230 - Release Date: 11/03/10
>16:36:00
More information about the bitc-dev
mailing list