Tag: C++11
40 posts
-
[2026] C++ std::function vs Function Pointers: Flexibility vs Speed
std::function vs raw function pointers: pointers are faster and smaller; std::function type-erases lambdas with captures and functors. Callback design, ...
-
[2026] C++ Atomic Operations | Atomic Operations Guide
C++ std::atomic and how to prevent data races in multithreads using atomic operations. Explains the advantages over mutexes and practical code patterns.
-
[2026] C++ auto Keyword | Type Deduction Complete Guide
Use the C++ auto keyword for type deduction: fewer repeated type names, deduction rules, iterators, lambdas, and pitfalls. Practical guide for modern C++.
-
[2026] C++ std::bind | Placeholders and partial application
std::bind is a function introduced in C++11 that creates a new function object by pre-binding a function and its arguments. It is used for partial appli...
-
[2026] C++ constexpr Functions | Compile-Time Functions Explained
C++ constexpr functions: compile-time and runtime use, C++11 vs C++14 vs C++17, arrays, classes, and optimization. Practical examples and pitfalls.
-
[2026] C++ decltype | Extract Expression Types
decltype vs auto, decltype(auto), trailing return types, SFINAE with decltype, and the decltype(x) vs decltype((x)) pitfall for templates.
-
[2026] C++ =default and =delete: Special Members, ODR, and Rule of Zero
C++11 =default and =delete: controlling special members, non-copyable types, deleted conversions, heap-only types, Rule of Five vs Rule of Zero, and noe...
-
[2026] C++ std::distribution | Probability distributions in the random header
Guide to C++11 random distributions: uniform_int, uniform_real, normal, Bernoulli, Poisson, and discrete. Engine pairing, parameter ranges, and thread-s...
-
[2026] C++ enum class | Scoped Enumerations Explained
Strongly typed scoped enums in C++11: no implicit int conversion, explicit underlying types, switch hygiene, and bit flags with constexpr helpers.
-
[2026] C++ Initializer-List Constructors | `std::initializer_list` Ctors Explained
Constructors taking std::initializer_list enable `{1,2,3}` initialization. They often win overload resolution over `T(int)` for `{}`—design APIs careful...
-
[2026] C++ std::initializer_list | Brace Lists for Functions and Containers
std::initializer_list (C++11) is a lightweight view over a brace-enclosed list. Used for container init and variadic-like APIs—not a full container; wat...
-
[2026] C++ inline Namespace: Versioning, API Evolution, and ADL
inline namespace in C++11+: lifting names into the parent namespace, API versioning, ABI notes, and differences from anonymous namespaces.
-
[2026] C++ Lambdas: Syntax, Captures, mutable, and Generic Lambdas
Complete guide to C++ lambda expressions: capture lists, mutable lambdas, C++14 generic lambdas, STL algorithms, and common pitfalls (dangling captures).
-
[2026] C++ Move Constructor: rvalue Stealing & noexcept Best Practices
C++ move constructors: rvalue resource transfer, copy vs move, vector and noexcept, self-move, and when not to std::move return locals.
-
[2026] C++ noexcept Complete Guide | Exception Specifications & Move Optimization
Master C++ noexcept: exception specifications, conditional noexcept, why move operations need noexcept for container optimization, terminate on violatio...
-
[2026] C++ noexcept Specifier: Contracts, Moves, and std::terminate
C++ noexcept explained: exception contracts, conditional noexcept, move constructors, vector behavior, and the noexcept operator.
-
[2026] C++ nullptr vs NULL | Type-Safe Null Pointers
Why C++11 nullptr beats NULL and literal 0: std::nullptr_t, overload resolution, template deduction, and migration tips including clang-tidy modernize-u...
-
[2026] C++ override & final: Virtual Overrides, Devirtualization, and API Sealing
C++ override and final: catching signature mistakes, sealing classes and virtual functions, devirtualization and performance notes, and practical patter...
-
[2026] C++ packaged_task | Package Task Guide
std::packaged_task is a C++11 feature that wraps a function or callable object and allows you to receive the result as a std::future. Unlike std::async,...
-
[2026] C++ std::random_device | Hardware entropy for seeding
How random_device maps to OS entropy, using entropy(), seed_seq for mt19937, UUID and token examples, performance vs mt19937, and platform quirks when e...
-
[2026] C++ random | Engines, distributions, and replacing rand()
C++11 random: random_device seeding, mt19937, uniform and normal distributions, shuffle, weighted picks, threading, and when to use a cryptographic RNG ...
-
[2026] C++ random numbers | Complete Guide to the C++11 random library
Why rand() is problematic, how to use random_device, mt19937, and distributions in C++11, with dice simulations, shuffling, weighted picks, seeding, and...
-
[2026] C++ std::regex | Regular expressions in C++11
Complete guide to C++11 regex: regex_match vs regex_search, regex_replace, capture groups, sregex_iterator, raw strings, performance, ECMAScript syntax,...
-
[2026] C++ sregex_iterator | Regex iterators for all matches
Use sregex_iterator and sregex_token_iterator to enumerate matches, split tokens, avoid dangling iterators, and handle empty matches and UTF-8 limits wi...
-
[2026] C++ std::chrono::steady_clock | Monotonic time for benchmarks
Use steady_clock for elapsed time and timeouts: monotonic guarantees vs system_clock, comparison with high_resolution_clock, benchmarking patterns, and ...
-
[2026] C++ thread_local | Thread-Local Storage (TLS) Complete Guide
C++11 thread_local: per-thread storage, caches, RNGs, initialization, and patterns without shared mutex overhead. Start now.
-
[2026] C++ time_point | Time Points Guide
C++ std::chrono::time_point represents a point in time on a specific clock. It is used with duration, and the resolution can be changed with time_point_...
-
[2026] C++ tuple detailed Complete Guide | Tuple guide
C++ tuple: basic usage, structured binding (C++17), principles, code, and practical applications. 실전 예제와 코드로 개념부터 활용까지 정리합니다. C++·tuple·pair 중심으로 설명합니다.
-
[2026] C++ Tuple Cheat Sheet | std::tuple, tie, and Structured Bindings
std::tuple basics: make_tuple, get, tie, tuple_cat, structured bindings (C++17), and common pitfalls for multi-value returns.
-
[2026] C++ Uniform Initialization | Braces `{}` Explained
Uniform initialization (C++11) uses `{}` for every type: scalars, arrays, structs, classes, and containers. Narrowing checks, the Most Vexing Parse, and...
-
[2026] C++ Universal (Forwarding) References Explained
Forwarding references: when T&& or auto&& deduces to bind both lvalues and rvalues, how they differ from rvalue references, and using std::forward corre...
-
[2026] C++ User-Defined Literals Complete Guide | Custom Suffix Operators
Everything about C++ User-Defined Literals Complete : from basic concepts to practical applications. Master key content quickly with examples.hello_s,...
-
[2026] C++ Value Initialization | Empty `{}` and `()`
Value initialization uses empty `()` or `{}`. Scalars become zero-like; classes call the default constructor. Differs from default initialization for lo...
-
[2026] C++ Variadic Templates | Complete Guide to Parameter Packs
Learn C++ variadic templates: typename...Args, pack expansion, sizeof..., fold expressions, and recursive patterns—with examples for generic printf, tup...
-
[2026] C++ async & launch | Asynchronous Execution Guide
Everything about C++ async & launch : from basic concepts to practical applications. Master key content quickly with examples.
-
[2026] C++ auto Type Deduction | Let the Compiler Handle Complex Types
C++ auto keyword and type deduction. Using auto with iterators, lambdas, and template return types, along with deduction rules and caveats.
-
[2026] C++ duration | Time Interval Guide
Everything about C++ duration : from basic concepts to practical applications. Master key content quickly with examples.
-
[2026] C++ explicit Keyword | explicit Keyword Guide
C++ explicit. Preventing implicit conversions, constructors, and conversion operators. Start now.
-
[2026] C++ nullptr | Null Pointer Guide
Complete guide to C++11 nullptr: differences from NULL and 0, function overloading, nullptr_t, and migration strategies. Master type-safe null pointers ...
-
[2026] What Is C++? History, Standards (C++11–23), Use Cases, and How to Start
C++ overview for beginners: evolution from C, C++11/17/20/23, game/systems/finance use cases, pros and cons, myths, learning roadmap, and production pat...