¡@

Home 

c++ Programming Glossary: violate

static variable in the class declaration or definition?

http://stackoverflow.com/questions/11178434/static-variable-in-the-class-declaration-or-definition

that is its own storage for the variable . This would violate the One Definition Rule . A consequence would be e.g. that if..

Why exactly do I need an explicit upcast when implementing QueryInterface() in an object with multiple interfaces()

http://stackoverflow.com/questions/1742848/why-exactly-do-i-need-an-explicit-upcast-when-implementing-queryinterface-in-a

The documents usually say that if I do the latter I will violate the requirement that any call to QueryInterface on the same..

C++0x memory model and speculative loads/stores

http://stackoverflow.com/questions/2001913/c0x-memory-model-and-speculative-loads-stores

is not written to and that this transformation would violate those conditions. I speculate that if y 2 then your original..

Is it legal/well-defined C++ to call a non-static method that doesn't access members through a null pointer?

http://stackoverflow.com/questions/3257393/is-it-legal-well-defined-c-to-call-a-non-static-method-that-doesnt-access-mem

then not see the expected crash. My question is does it violate the C standard to call SomeFooPtr bar where SomeFooPtr NULL..

Optimizing away a “while(1);” in C++0x

http://stackoverflow.com/questions/3592557/optimizing-away-a-while1-in-c0x

atomic operations or that it eventually terminates. If I violate that assumption by writing an infinite loop with no side effects..

What are Aggregates and PODs and how/why are they special?

http://stackoverflow.com/questions/4178175/what-are-aggregates-and-pods-and-how-why-are-they-special

data members and member functions as you like and not violate the rules for aggregate classes An aggregate class can have..

What is the proper declaration of main?

http://stackoverflow.com/questions/4207134/what-is-the-proper-declaration-of-main

Have those rules changed over time What happens if I violate them c main c faq share improve this question The main.. a return type of void this is probably the most frequently violated rule concerning the main function . There are two declarations..

static keyword in h file and internal linkage

http://stackoverflow.com/questions/4276794/static-keyword-in-h-file-and-internal-linkage

as in the definition in another translation unit. You violate this because counter has internal linkage so in different translation..

Another bug in g++/Clang? [C++ Templates are fun]

http://stackoverflow.com/questions/4420828/another-bug-in-g-clang-c-templates-are-fun

put a template argument list onto a non template and also violate the requirement quoted in the last part you use the name elsewhere..

C++ static member variable and its initialization

http://stackoverflow.com/questions/4547660/c-static-member-variable-and-its-initialization

be defined in exactly one translation unit in order to not violate the One Definition Rule . If the language were to allow something.. and c there is still a definition somewhere that doesn't violate the one definition rule file gizmo.cpp #include gizmo.h const..

Container covariance in C++

http://stackoverflow.com/questions/4807643/container-covariance-in-c

c covariance share improve this question The rule violated here is documented in C 03 3.10 15 basic.lval which specifies.. Derived . The compiler could do all sorts of things if you violate this rule including perform different optimizations on one than..

What legitimate reasons exist to overload the unary operator&?

http://stackoverflow.com/questions/6495977/what-legitimate-reasons-exist-to-overload-the-unary-operator

Returning anything other than a legitimate pointer would violate the principle of least astonishment . share improve this answer..

Memory model ordering and visibility?

http://stackoverflow.com/questions/7461484/memory-model-ordering-and-visibility

that it must be agreed on by all threads and it must not violate other ordering constraints. In particular threads may continue..

Isn't C++'s inline totally optional?

http://stackoverflow.com/questions/908830/isnt-cs-inline-totally-optional

is different since the function is non inline. You will violate the ODR since you have more than one definition of f if you.. the class but then omit defining it in the header then you violate 3.2 3 and 7.1.2 4 which says the same thing just more elaborating..

Inheritance: 'A' is an inaccessible base of 'B'

http://stackoverflow.com/questions/9661936/inheritance-a-is-an-inaccessible-base-of-b

as if it were a vector . Doing so could and likely would violate the expectations of a stack e.g. the user could insert remove..

strict aliasing and alignment

http://stackoverflow.com/questions/9964418/strict-aliasing-and-alignment

of conversion through union does not in fact allow you to violate aliasing. Only one member of a union is allowed to be active.. level. For example the following is legal and does not violate strict aliasing rules int a 2 double d static_assert sizeof..