Die Anordnung im Speicher ist definiert, nur nicht die exakte Sequenz
der Pointerwerte.
Speicher: "An array type describes a contiguously allocated nonempty set
of objects with a particular member object type, called the element
type." und "All objects in C must be representable as a contiguous
sequence of bytes, each of which is at least 8 bits wide."
Pointer: "Consider a hypothetical segmented architecture on which
pointers comprise a segment descriptor and an offset. Suppose that
segments are relatively small so that large arrays are allocated in
multiple segments. While the segments are valid (allocated, mapped to
real memory), the hardware, operating system, or C implementation can
make these multiple segments behave like a single object: pointer
arithmetic and relational operators use the defined mapping to impose
the proper order on the elements of the array."
(C99 Reference/Rationale)
Axel Schwenke schrieb:
> Anders gesagt: wenn ein (void) Pointer x auf
> Adresse X zeigt, dann ist nicht garantiert daß x+1 auf Adresse X+1
> zeigen wird.
Da wir grad so schön dabei sind, Häärlein zu spalten: Mit void* kannst
du nicht rechnen. ;-)