Forums
New posts
Search forums
Members
Current visitors
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Menu
Log in
Register
Install the app
Install
Forums
Archive
Archive
C Programming
Bounds checked arrays
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
Reply to thread
Message
[QUOTE="Keith Thompson, post: 1702213"] AS/400? Can you provide a pointer to your proposal? I'd be interested in seeing it. Indexing into a description array saves space in each pointer, but since each pointer dereference has to refer to the bounds information, putting it in the pointer itself might make for faster execution. [...] It might be an interesting exercise to design a new language (as close to C as possible, but no closer) that incorporates this kind of bounds checking. If it can't be done without breaking existing code, then there's little chance of the new language being called C, but there seems to be a market advantage in designing new languages with C-like syntax, even if they're incompatible (see Java and Perl, for example). If a lot of existing C code can be ported to the new language without too much effort, it might even catch on. It would probably need to have a mechanism for working with C-style skinny pointers so it could interface to existing C code (OS interfaces, for example); such a mechanism should be very explicit so programmers aren't tempted to use it by default (perhaps a type qualifier called "dangerous"). And I think I've just jumped off the cliff of topicality into the icy fjord of speculative language design. [/QUOTE]
Verification
Post reply
Forums
Archive
Archive
C Programming
Bounds checked arrays
Top