[llvm-commits] [llvm] r86572 - /llvm/trunk/docs/LangRef.html
Dan Gohman
gohman at apple.com
Mon Nov 9 11:03:12 PST 2009
On Nov 9, 2009, at 10:52 AM, Duncan Sands wrote:
> Hi Dan,
>
>> +<p>Except when the <tt>inbounds</tt> keyword is present, there is no limitation
>> + on indexing beyond the end of the array implied by the static type (though
>> + any loads or stores must of course be within the bounds of the allocated
>> + object!). This means that single-dimension 'variable sized array' addressing
>> + can be implemented in LLVM with a zero length array type. An implementation
>> + of 'pascal style arrays' in LLVM could use the type
>> + "<tt>{ i32, [0 x float]}</tt>", for example.</p>
>
> does this mean that "inbounds" means that you are not allowed to index off the
> end of the *type*, even if you are not indexing off the end of the allocated
> object?
No; it means I made a mistake. Thanks!
Dan
More information about the llvm-commits
mailing list