Цитата(GetSmart @ Jan 4 2009, 19:05)

Если, теоретически, структуры могут иметь этот атрибут,
Конечно могут, как и любые другие типы данных. Применение модификатора
volatile (также как и
const) к структуре распространяет его на все члены структуры.
Цитата(zltigo @ Jan 4 2009, 19:49)

Проблема в том, что компилятор плюсовый.
Точнее это бага плюсового компилятора. Я все-таки залез в стандарт С++, и вот что он пишет:
Цитата
1.9 Program execution
6. The observable behavior of the abstract machine is its sequence of reads and writes to volatile data and calls to library I/O functions.
7. Accessing an object designated by a volatile lvalue (3.10), modifying an object, calling a library I/O function, or calling a function that does any of those operations are all side effects, which are changes in the state of the execution environment. [...]
7.1.5.1 The cv-qualifiers
8. [Note: volatile is a hint to the implementation to avoid aggressive optimization involving the object because the value of the object might be changed by means undetectable by an implementation. See 1.9 for detailed semantics. In general, the semantics of volatile are intended to be the same in C++ as they are in C. ]