volatile [was: GCC warnings for unused global variables]
Michael Eager
eager@eagercon.com
Thu May 8 15:37:00 GMT 2003
Gabriel Dos Reis wrote:
> Fergus Henderson <fjh@cs.mu.OZ.AU> writes:
>
> | The C++ committee was not too worried about nailing down the semantics
> | of volatile for class objects, since they did not expect it to be used
> | (or useful) for class objects.
>
> This statement is clearly wrong since the committee does consider
> member functions that are volatile-qualified which, for one thing, is
> an indication that volatile was expected to be used with classes.
That only concerns syntax, not sematics. Const and volatile tags
on member functions must match the data. Whether this was useful
or not was not at issue.
--
Michael Eager Eager Consulting eager@eagercon.com
1960 Park Blvd., Palo Alto, CA 94306 650-325-8077
More information about the Gcc
mailing list