Liste des Groupes | Revenir à cl c |
On 2024-07-07, James Kuyper <jameskuyper@alumni.caltech.edu> wrote:
>On 7/7/24 16:10, BGB wrote:>
>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).
I think that the existence of an implicit pointer would be a bad thing
to acknowledge, given that the language doesn't require that it exist,
and typical implementations don't use them. From what I understand, the
fact that your implementation does have implicit pointers makes it a rarity.
Ritchie's B language had arrays which contained a pointer to their
first element. Via a hack, it was possible to relocate an array.
>
In C, such a thing is not simply not required; it is ruled out
by the detailed semantic description of arrays. [...]
Les messages affichés proviennent d'usenet.