[ First ]  [ Previous ]  [ Next ]  [ Last ]  [ Manuals ]


Using Typecasted Pointers as lvalues

The C compiler can accept a pointer that you typecast to another pointer type as an lvalue.

For example:


char *cp;
((long *) cp)++;  /* OK if ANSI Strict is off. */

To turn this feature on, turn off the ANSI Strict setting in the C/C++ Language Panel. If the ANSI Strict setting is on, then this extension to standard C is disabled.

See also: "ANSI Strict."


[ First ]  [ Previous ]  [ Next ]  [ Last ]  [ Manuals ]

Visit the Metrowerks website at: http://www.metrowerks.com
For assistance contact Metrowerks Technical Support at: cw_support@metrowerks.com
Copyright © 2000, Metrowerks Corp. All rights reserved.

Last updated: August 17, 2000