c++ Programming Glossary: used
What is an undefined reference/unresolved external symbol error and how do I fix it? http://stackoverflow.com/questions/12573816/what-is-an-undefined-reference-unresolved-external-symbol-error-and-how-do-i-fix symbol a in a.cpp . Now b.cpp declared that symbol and used it. Before linking it simply assumes that that symbol was defined.. not visible. Symbols were defined in a C program and used in C code. Incorrectly importing exporting methods classes accross..
Why is “using namespace std;” considered bad practice? http://stackoverflow.com/questions/1452721/why-is-using-namespace-std-considered-bad-practice if the function parameters happen to match. If you have used foo Blah and bar Quux then the introduction of foo Quux would..
What are the rules about using an underscore in a C++ identifier? http://stackoverflow.com/questions/228783/what-are-the-rules-about-using-an-underscore-in-a-c-identifier a capital 'E' followed a digit or uppercase letter may be used for additional error code names. See Error Reporting. Names.. either 'is' or 'to' followed by a lowercase letter may be used for additional character testing and conversion functions. Names.. begin with 'LC_' followed by an uppercase letter may be used for additional macros specifying locale attributes. Names of..
What is the copy-and-swap idiom? http://stackoverflow.com/questions/3279543/what-is-the-copy-and-swap-idiom and swap idiom What is this idiom and when should it be used Which problems does it solve Does the idiom change when C 11.. problems does it solve Does the idiom change when C 11 is used Although it's been mentioned in many places we didn't have any.. that this is non throwing because of the data types being used more attention to detail with regards to exceptions must be..
What can I use to profile C++ code in Linux? http://stackoverflow.com/questions/375913/what-can-i-use-to-profile-c-code-in-linux tend to be skeptical of this technique unless they've used it themselves. They will say that profilers give you this information..
What is The Rule of Three? http://stackoverflow.com/questions/4172722/what-is-the-rule-of-three The implementation will implicitly define them if they are used. ... end note n3126.pdf section 12 §1 By default copying an..
Operator overloading http://stackoverflow.com/questions/4421706/operator-overloading Function call operator The function call operator used to create function objects also known as functors must be defined.. as innocently looking as a list iterator . Once you got used to do i it becomes very hard to remember to do i instead when.. to observe that the compound assignment operators can be used as a base for their non compound counterparts. That is operator..
How do I use arrays in C++? http://stackoverflow.com/questions/4810664/how-do-i-use-arrays-in-c use arrays in C C inherited arrays from C where they are used virtually everywhere. C provides abstractions that are easier.. context triggers array to pointer decay can x and x 0 be used interchangeably. For example T p array 0 rewritten as array..
Where and why do I have to put the “template” and “typename” keywords? http://stackoverflow.com/questions/610245/where-and-why-do-i-have-to-put-the-template-and-typename-keywords by itself but by the type dependent argument expressions used in a call. In the example f T 0 f is a dependent name. In the.. it in a certain way. The Standard says at 14.6 2 A name used in a template declaration or definition and that is dependent.. It can appear in the middle before a class name that's used as a scope like in the following example typename t template..
Can a local variable's memory be accessed outside its scope? http://stackoverflow.com/questions/6441218/can-a-local-variables-memory-be-accessed-outside-its-scope that when the stack logically shrinks the addresses that used to be valid are still mapped into memory. The implementation..
Create std::list of value instead of std::list of pointers in recursive function http://stackoverflow.com/questions/11335738/create-stdlist-of-value-instead-of-stdlist-of-pointers-in-recursive-function nullptr depth 0 obj parent list obj children int depth Used only for this example And to fill my data structure I use a..
Write your own memory manager http://stackoverflow.com/questions/1194479/write-your-own-memory-manager
How to print a double with a comma http://stackoverflow.com/questions/1422151/how-to-print-a-double-with-a-comma const return m_Separator private CharT m_Separator Used as std cout.imbue std locale std cout.getloc new DecimalSeparator..
How to make generic computations over heterogeneous argument packs of a variadic template function? http://stackoverflow.com/questions/14261183/how-to-make-generic-computations-over-heterogeneous-argument-packs-of-a-variadic THE UNDERLYING TYPE OF HOMOGENEOUS PARAMETER PACKS Used as the underlying type of non homogeneous parameter packs struct..
Python/C++ Binding Library comparison http://stackoverflow.com/questions/1492755/python-c-binding-library-comparison Very well documented easy to follow setup instructions Used by Google hey that's got to count for SOMETHING right Boost..
Scripting language for C/C++? http://stackoverflow.com/questions/1513920/scripting-language-for-c-c Developed as part of the ROOT environment at the CERN . Used by many physicist. ccons http code.google.com p ccons An interactive..
Virtual Webcam Driver http://stackoverflow.com/questions/1627448/virtual-webcam-driver from Microsoft which provide access to image data. Twain Used for single image capture from scanners etc. WIA This seems to..
Using “super” in C++ http://stackoverflow.com/questions/180601/using-super-in-c
GCC error with variadic templates: “Sorry, unimplemented: cannot expand 'Identifier…' into a fixed-length argument list” http://stackoverflow.com/questions/1989552/gcc-error-with-variadic-templates-sorry-unimplemented-cannot-expand-identi what is about my code that is causing this specific error Used as a container for a set of types. template typename... Types..
how to sum a large number of float number? http://stackoverflow.com/questions/2148149/how-to-sum-a-large-number-of-float-number the p sum is mysum endl clock_t finish clock cout Time Used finish start CLOCKS_PER_SEC endl mysum 0 for int i 0 i N i mysum..
How to make SIMPLE C++ Makefile? http://stackoverflow.com/questions/2481269/how-to-make-simple-c-makefile because we want to link multiple object files. Variables Used By Built in Rules The built in rules use a set of standard variables..
LRU cache design http://stackoverflow.com/questions/2504178/lru-cache-design cache design Least Recently Used LRU Cache is to discard the least recently used items first..
When and why will an OS initialise memory to 0xCD, 0xDD, etc. on malloc/free/new/delete? http://stackoverflow.com/questions/370195/when-and-why-will-an-os-initialise-memory-to-0xcd-0xdd-etc-on-malloc-free-new Memory Memory that has been released with delete or free. Used to detect writing through dangling pointers. 0xED or Aligned.. end or start of an allocated block. 0xFD or Buffer slack Used to fill slack space in some memory buffers 0xFE unused parts..
Pretty-print C++ STL containers http://stackoverflow.com/questions/4850473/pretty-print-c-stl-containers std pair T1 T2 TChar values.postfix return stream Used by the sample below to generate some values struct fibonacci..
Smart Pointers: Or who owns you baby? [closed] http://stackoverflow.com/questions/94227/smart-pointers-or-who-owns-you-baby the object. Transfer of ownership is NOT allowed. Usage Used to show explicit ownership. Object will be destroyed by destructor.. can not be determined at compile time. boost weak_ptr T Used with shared_ptr T . In situations where a cycle of pointers.. In situations where a cycle of pointers may happen. Usage Used to stop cycles from retaining objects when only the cycle is..
Checking a member exists, possibly in a base class, C++11 version http://stackoverflow.com/questions/9530928/checking-a-member-exists-possibly-in-a-base-class-c11-version T t decltype t.reserve 0 bool return true Used as fallback when SFINAE culls the template method constexpr..
|