04.01.2015 Views

RealView Compilation Tools - ARM Information Center

RealView Compilation Tools - ARM Information Center

RealView Compilation Tools - ARM Information Center

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Compiler-specific Features<br />

Syntax<br />

__alignof__(type)<br />

__alignof__(expr)<br />

Where:<br />

type<br />

expr<br />

is a type<br />

is an lvalue.<br />

Return value<br />

__alignof__(type) returns the alignment requirement for the type type, or 1 if there is<br />

no alignment requirement.<br />

__alignof__(expr) returns the alignment requirement for the type of the lvalue expr, or<br />

1 if there is no alignment requirement.<br />

Example<br />

int Alignment_0(void)<br />

{<br />

return __alignof__(int);<br />

}<br />

See also<br />

• __ALIGNOF__.<br />

4.1.3 __ALIGNOF__<br />

The __ALIGNOF__ keyword returns the alignment requirement for a specified type, or for<br />

the type of a specified object.<br />

Syntax<br />

__ALIGNOF__(type)<br />

__ALIGNOF__(expr)<br />

Where:<br />

type<br />

expr<br />

is a type<br />

is an lvalue.<br />

4-4 Copyright © 2007-2010 <strong>ARM</strong>. All rights reserved. <strong>ARM</strong> DUI 0348C<br />

Non-Confidential,<br />

ID101213

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!