Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
vector destruction - clang
//clang #include <iostream> #include <vector> struct A{ A(int i):i_(i){} ~A(){ std::cout << i_ << std::endl; } int i_; }; int main() { std::vector<A> a({0,1,2,3,4,5}); std::cout << "Destroy a " << std::endl; }
run
|
edit
|
history
|
help
0
Throttle Example in C++
Tilted uniform distribution random number generator over min/max range
wasm test for node
Linker error while taking the address of a constexpr variable
Unlike C (even C99/C11), C++ allows initializers in if-conditions, so this compiles.
Example
Crow unordered_map Quiz
problem_name_1
Forgetting to check end
Virtual Function Example