Re: __gc arrays

Rhys Weatherley <[email protected]>
Newsgroups gmane.comp.gnu.dotgnu.developer
Organization Southern Storm Software, Pty Ltd
Message-ID <[email protected]>
On Wednesday 21 April 2004 09:44 am, Alex Stephens wrote:
> Thanks Rhys. I'm aware that cscc is a C compiler but I don't see why this
> should prevent managed arrays. In fact, I can get a managed array in cscc
> using: __box int array[]=new __box int[10];
> but then it won't work with normal subscripting i.e. array[0]=0; gives
> "subscripted value is neither array nor pointer" error.

That's probably a bug.  Please log it in Savannah so we don't forget about it.  
Or better yet, have a look at the cscc code and try to fix it yourself and 
submit a patch.  We definitely need more people working on the C compiler.

> If this
> functionality is not already implemented, I think it would make a very
> useful contribution to pnet (no buffer overflows or memory leaks in C
> code).

Since it requires the programmer to take explicit action to use, I have never 
really understood how it helps prevent sloppy programming.

Cheers,

Rhys.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.