Sujet : Re: technology discussion → does the world need a "new" C ?
De : cr88192 (at) *nospam* gmail.com (BGB)
Groupes : comp.lang.cDate : 07. Jul 2024, 21:10:51
Autres entêtes
Organisation : A noiseless patient Spider
Message-ID : <v6esqm$fian$2@dont-email.me>
References : 1 2 3 4 5 6 7 8 9 10 11
User-Agent : Mozilla Thunderbird
On 7/7/2024 9:03 AM, James Kuyper wrote:
On 7/7/24 00:55, BGB wrote:
On 7/6/2024 5:38 PM, Keith Thompson wrote:
...
No, there is no implicitly defined pointer.
...
This implicit pointer need not exist at a location in memory...
Which is why C doesn't give you access to it's location in memory -
something you complained about earlier.
I don't think I was claiming that one should have direct access to its location or value within the language, rather that their existence and behaviors could be acknowledged in the language design (for a "not quite C" language).
My existing compiler uses such pointers internally, but does not give programs the ability to access their contents (as this would basically open up a crap storm in the semantics; and there is the "less bad" option of "just use pointers").
Well, and potentially, one can argue, that the existence or non-existence of such pointers could potentially influence the behavior of the program in some edge cases (well, along with things like turning large local arrays or structs into implicit memory allocations).
Like, say, an implicit malloc call is still a malloc call...
But alas (seemingly it is a necessary evil absent reserving MB of memory for the stack for many programs...).
...