Advertisement
here2share

C++ Reserved v2

Apr 24th, 2021
797
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 16.39 KB | None | 0 0
  1. C++ Reserved v2
  2.  
  3. Commonly Used Keywords:
  4.  
  5. auto
  6. bool
  7. break
  8. case
  9. catch
  10. char
  11. class
  12. const
  13. constexpr
  14. continue
  15. decltype
  16. default
  17. delete
  18. do
  19. double
  20. else
  21. enum
  22. extern
  23. false
  24. float
  25. for
  26. if
  27. int
  28. long
  29. namespace
  30. new
  31. noexcept
  32. nullptr
  33. operator
  34. private
  35. protected
  36. public
  37. return
  38. short
  39. signed
  40. sizeof
  41. static
  42. static_assert
  43. static_cast
  44. struct
  45. switch
  46. template
  47. this
  48. throw
  49. true
  50. try
  51. typedef
  52. typename
  53. unsigned
  54. using
  55. virtual
  56. void
  57. while
  58.  
  59.  
  60.  
  61. Seldomly Used Keywords:
  62.  
  63. alignas
  64. alignof
  65. asm
  66. char16_t
  67. char32_t
  68. wchar_t
  69. const_cast
  70. dynamic_cast
  71. reinterpret_cast
  72. explicit
  73. export
  74. friend
  75. goto
  76. inline
  77. mutable
  78. thread_local
  79. typeid
  80. union
  81. volatile
  82.  
  83.  
  84.  
  85. Alternative Keywords:
  86.  
  87. and
  88. and_eq
  89. bitand
  90. bitor
  91. compl
  92. not
  93. not_eq
  94. or
  95. or_eq
  96. xor
  97. xor_eq
  98.  
  99.  
  100.  
  101. Unused Keywords since C++ 17:
  102.  
  103. register
  104.  
  105.  
  106.  
  107. New Keywords in C++ 20:
  108.  
  109. char8_t
  110. concept
  111. consteval
  112. constinit
  113. concept
  114. co_await
  115. co_return
  116. co_yield
  117. requires
  118.  
  119.  
  120.  
  121. Upcoming Keywords as of Technical Specification:
  122.  
  123. reflexpr
  124. atomic_cancel
  125. atomic_commit
  126. atomic_noexcept
  127. synchronized
  128.  
  129.  
  130.  
  131. Special Identifiers (they are different from Keywords)
  132. - these are the identifiers that has special meanings in some contexts which means you can redefine them as long as you don't define them in said context.
  133.  
  134. final
  135. override
  136. import
  137. module
  138. Special Identifiers as of Technical Specification:
  139. transaction_safe
  140. transaction_safe_dynamic
  141.  
  142.  
  143.  
  144.  
  145. These are all possible reserved words in STL (Standard Template Library). You can safely use the existing identifiers in STL if you properly use the `std` namespace or the syntax `std::`.
  146. These are all identifiers used by STL C++ --
  147.  
  148. Part 1:
  149. __gnu_cxx accumulate add_const add_cv add_lvalue_reference add_pointer add_reference add_rvalue_reference add_volatile adjacent_difference adjacent_find aligned_storage Alignment alignment_of all_of allocate_shared allocator allocator_base allo… See More
  150.  
  151. Part 2:
  152. exponential_distribution extent extreme_value_distribution fetch_add fetch_and fetch_or fetch_sub fetch_xor filebuf fill fill_n find find_end find_first_of find_first_not_of find_if find_if_not find_last_of find_last_not_of fisher_f_distribution float_denorm_style float_round_style for_each forward forward_iterator_tag forward_list freelist front front_insert_iterator front_item fstream function gamma_distribution generate generate_n generic_container generic_iterator generic_reverse_iterator generic_value geometric_distribution get_deleter get_pointer_safety get_temporary_buffer greater greater_equal has_nothrow_assign has_nothrow_constructor has_nothrow_copy has_nothrow_copy_assign has_nothrow_copy_constructor has_nothrow_default_constructor has_trivial_assign has_trivial_constructor has_trivial_copy has_trivial_copy_assign has_trivial_copy_constructor has_trivial_default_constructor has_trivial_destructor has_virtual_destructor hash hash_map hash_set ifstream includes independent_bits_engine initializer_list inner_product inplace_merge input_iterator_tag insert insert_iterator integral_constant invalid_argument ios_base iostream is_abstract is_arithmetic is_array is_base_of is_bind_expression is_class is_compound is_const is_constructible is_convertible is_empty is_enum is_error_code_enum is_error_condition_enum is_explicitly_convertible is_floating_point is_function is_fundamental is_heap is_heap_until is_integral is_literal_type is_lock_free is_lvalue_reference is_member_function_pointer is_member_object_pointer is_member_pointer is_nothrow_constructible is_object is_partitioned is_placeholder is_pod is_pointer is_polymorphic is_reference is_rvalue_reference is_same is_scalar is_signed is_sorted is_sorted_until is_standard_layout is_trivial is_union is_unsigned is_void is_volatile istream istream_iterator istreambuf_iterator iter_swap iterator iterator_traits knuth_b length_error less less_equal LessThanComparable lexicographical_compare linear_congruential linear_congruential_engine list locale logic_error logical_and logical_not logical_or lognormal_distribution lower_bound make_checked_array_iterator make_heap make_shared make_signed make_unsigned map match_results max max_element max_fixed_size max_none max_unbounded max_variable_size mem_fn mem_fun mem_fun_ref mem_fun_ref_t mem_fun_t mem_fun1_ref_t mem_fun1_t merge mersenne_twister mersenne_twister_engine messages messages_base messages_byname min min_element minmax minmax_element minstd_rand minstd_rand0 minus mismatch modulus money_base money_get money_put moneypunct moneypunct_byname move move_backward move_iterator mt19937 mt19937_64 multimap multiplies multiset negate negative_binomial_distribution new_handler next_permutation none_of normal_distribution not_equal_to not1 not2 nothrow nothrow_t npos nth_element num_get num_put numeric_limits numpunct numpunct_byname ofstream ostream_iterator ostreambuf_iterator out_of_range output_iterator_tag overflow_error owner_less pair partial_sort partial_sort_copy partial_sum partition partition_copy partition_point piecewise_constant_distribution piecewise_linear_distribution plus pointer_safety pointer_to_binary_function pointer_to_unary_function poisson_distribution pop_back pop_front pop_heap prev_permutation priority_queue ptr_fun push_back push_front push_heap queue random_access_iterator_tag random_device random_shuffle range_error rank ranlux_base_01 ranlux24 ranlux24_base ranlux3 ranlux3_01 ranlux4 ranlux4_01 ranlux48 ranlux48_base ranlux64_base_01 ratio ratio_add ratio_divide ratio_multiply ratio_subtract
  153.  
  154. Part 3:
  155. raw_storage_iterator rbegin rdbuf ref reference reference_wrapper regex regex_constants regex_error regex_iterator regex_token_iterator regex_traits remove remove_all_extents remove_const remove_copy remove_copy_if remove_cv remove_extent remove_if remove_pointer remove_reference remove_volatile rend replace replace_copy replace_copy_if replace_if requires resize result_of return_temporary_buffer reverse reverse_view reverse_copy reverse_iterator rotate rotate_copy rts_alloc runtime_error search search_n seed_seq set set_difference set_intersection set_new_handler set_symmetric_difference set_union setprecision setw shared_ptr shuffle_order_engine size size_type sort sort_heap stable_partition stable_sort stack static_pointer_cast std streambuf string stringstream student_t_distribution sub_match substr subtract_with_carry subtract_with_carry_01 subtract_with_carry_engine swap swap_ranges sync_none sync_per_container sync_per_thread sync_shared system_error time_base time_get time_get_byname time_put time_put_byname to_array tr1 transform tuple tuple_element tuple_size type_info unary_function unary_negate unchecked_uninitialized_copy unchecked_uninitialized_fill_n undeclare_no_pointers undeclare_reachable underflow_error uniform_int uniform_int_distribution uniform_real uniform_real_distribution uninitialized_copy uninitialized_copy_n uninitialized_fill uninitialized_fill_n unique unique_copy unique_ptr unordered_map unordered_multimap unordered_multiset unordered_set upper_bound valarray value_type variate_generator vector wcerr wcin wcout weak_ptr weibull_distribution wfilebuf wfstream wifstream wiostream wistream wofstream wregex xor_combine fdfdf e same_as derived_from convertible_to common_reference_with common_with integral signed_integral unsigned_integral floating_point assignable_from swappable swappable_with destructible constructible_from default_initializable move_constructible copy_constructible equality_comparable equality_comparable_with totally_ordered totally_ordered_with movable copyable semiregular regular invocable regular_invocable predicate relation equivalence_relation strict_weak_order coroutine_traits coroutine_handle noop_coroutine_promise noop_coroutine_handle suspend_always suspend_never noop_coroutine bad_typeid bad_cast type_index bool_constant true_type false_type is_void_v is_null_pointer is_null_pointer_v is_integral_v is_floating_point_v is_array_v is_enum_v is_union_v is_class_v is_function_v is_pointer_v is_lvalue_reference_v is_rvalue_reference_v is_member_object_pointer_v is_member_function_pointer_v is_fundamental_v is_arithmetic_v is_scalar_v is_object_v is_compound_v is_reference_v is_member_pointer_v is_const_v is_volatile_v is_trivial_v is_trivially_copyable is_trivially_copyable_v is_standard_layout_v is_pod_v has_unique_object_representations has_unique_object_representations_v is_empty_v is_polymorphic_v is_abstract_v is_final is_final_v is_aggregate is_aggregate_v is_signed_v is_unsigned_v is_bounded_array is_bounded_array_v is_unbounded_array is_unbounded_array_v is_scoped_enum is_scoped_enum_v alignment_of_v rank_v extent_v is_same_v is_base_of_v is_convertible_v is_nothrow_convertible is_nothrow_convertible_v is_layout_compatible is_layout_compatible_v is_pointer_interconvertible_base_of is_pointer_interconvertible_base_of_v is_invocable is_invocable_v is_invocable_r is_invocable_r_v is_nothrow_invocable is_nothrow_invocable_v is_nothrow_invocable_r is_nothrow_invocable_r_v remove_cv_t remove_const_t remove_volatile_t add_cv_t add_const_t add_volatile_t remove_reference_t add_lvalue_reference_t add_rvalue_reference_t remove_pointer_t add_pointer_t make_signed_t make_unsigned_t remove_extent_t remove_all_extents_t aligned_storage_t aligned_union aligned_union_t decay_t remove_cvref remove_cvref_t enable_if_t conditional_t common_type_t underlying_type underlying_type_t invoke_result invoke_result_t void_t conjunction conjunction_v disjunction disjunction_v negation negation_v is_pointer_interconvertible_with_class is_corresponding_member is_constant_evaluated placeholder is_bind_expression_v is_placeholder_v bind_front invoke bit_not not_fn default_searcher boyer_moore_searcher boyer_moore_horspool_searcher rel_ops exchange move_if_noexcept as_const cmp_equal cmp_not_equal cmp_less cmp_greater cmp_less_equal cmp_greater_equal in_range make_pair integer_sequence piecewise_construct_t piecewise_construct in_place in_place_type in_place_index in_place_t in_place_type_t in_place_index_t
  156.  
  157. Part 4:
  158. duration chrono time_point treat_as_floating_point clock_time_conversion duration_values time_zone nonexistent_local_time ambiguous_local_time system_clock steady_clock high_resolution_clock utc_clock tai_clock gps_clock file_clock local_t clock_cast duration_cast ignore make_tuple tie forward_as_tuple tuple_cat get apply make_from_tuple any bad_any_cast any_cast make_any optional bad_optional_access nullopt_t nullopt make_optional variant monostate bad_variant_access variant_size variant_size_v variant_alternative variant_alternative_t variant_npos visit holds_alternative get_if three_way_comparable three_way_comparable_with partial_ordering weak_ordering strong_ordering common_comparison_category compare_three_way_result compare_three_way strong_order weak_order partial_order compare_strong_order_fallback compare_weak_order_fallback compare_partial_order_fallback is_eq is_neq is_lt is_lteq is_gt is_gteq source_location u8string u16string u32string wstring pmr stoi stol stoll stoul stoull stof stod stold to_string to_wstring starts_with ends_with contains rfind string_view basic_string_view u8string_view u16string_view u32string_view wstring_view chars_format from_chars to_chars formatter basic_format_parse_context format_parse_context wformat_parse_context basic_format_context format_context wformat_context basic_format_arg basic_format_args format_args wformat_args format_args_t format_error format format_to format_to_n formatted_size vformat vformat_to visit_format_arg make_format_args make_wformat_args syntax_option_type match_flag_type error_type span dynamic_extent as_byte as_writable_bytes indirectly_readable indirectly_writable weakly_incrementable incrementable input_or_output_iterator sentinel_for sized_sentinel_for input_iterator output_iterator forward_iterator bidirectional_iterator random_access_iterator contiguous_iterator indirectly_unary_invocable indirectly_regular_unary_invocable indirect_unary_predicate indirect_binary_predicate indirect_equivalence_relation indirect_strict_weak_order indirectly_movable indirectly_movable_storable indirectly_copyable indirectly_copyable_storable indirectly_swappable indirectly_comparable permutable mergeable sortable indirect_result_t projected incrementable_traits indirectly_readable_traits iter_value_t iter_reference_t iter_difference_t iter_rvalue_reference_t iter_common_reference_t contiguous_iterator_tag move_sentinel common_iterator default_sentinel_t counted_iterator unreachable_sentinel_t iter_move make_reverse_iterator make_move_iterator front_inserter back_inserter inserter ranges views range borrowed_range sized_range view input_range output_range forward_range bidirectional_range random_access_range contiguous_range common_range viewable_range iterator_t sentinel_t range_difference_t range_size_t range_value_t range_reference_t range_rvalue_reference_t view_interface subrange dangling borrowed_iterator_t borrowed_subrange_t empty_view single single_view iota iota_view basic_istream_view istream_view all all_t ref_view filter_view filter transform_view take_view take take_while_view take_while drop_view drop drop_while_view drop_while join_view join split_view split counted common_view common everse_view elements elements_view keys_view keys values_view values subrange_kind for_each_n first_end shift_left shift_right shuffle sample clamp lexicographical_compare_three_way is_permutation in_fun_result in_in_result in_out_result in_in_out_result in_out_out_result min_max_result in_found_result is_execution_policy sequenced_policy parallel_policy parallel_unsequenced_policy unsequenced_policy seq par par_unseq unseq float_t double_t slice slice_array gslice gslice_array mask_array indirect_array
  159.  
  160. Part 5:
  161. uniform_random_bit_generator reduce transform_reduce inclusive_scan exclusive_scan transform_inclusive_scan transform_exclusive_scan gcd lcm midpoint ratio_equal ratio_unequal ratio_less ratio_less_equal ratio_greater ratio_greater_equal endian bit_cast has_single_bit bit_ceil bit_floor bit_width rotl rotr countl_zero countl_one countr_zero countr_one popcount e e_v log2e log2e_v log10e log10e_v pi pi_v inv_pi inv_pi_v inv_sqrtpi inv_sqrtpi_v ln2 ln2_v ln10 ln10_v sqrt2 sqrt2_v sqrt3 sqrt3_v inv_sqrt3 inv_sqrt3_v egamma egamma_v phi phi_v basic_ios fpos io_errc streamoff streamsize iostream_category boolalpha noboolalpha showbase noshowbase showpoint noshowpoint showpos noshowpos skipws noskipws uppercase nouppercase unitbuff nounitbuff internal left right dec hex oct fixed scientific hexfloat defaultfloat basic_iostream basic_istream basic_ostream ostream wostream ends flush emit_on_flush no_emit_on_flush flush_emit clog wclog basic_stringbuf basic_istringstream basic_ostringstream basic_stringstream stringbuf wstringbuf istringstream wistringstream ostringstream wostringstream wstringstream basic_syncbuf basic_osyncstream syncbuf wsyncbuf osyncstream wosyncstream wstreambuf resetiosflags setiosflags setbase setfill get_money put_money get_time put_time quoted path filesystem_error directory_entry directory_iterator recursive_directory_iterator file_status space_info file_type perms perm_options copy_options directory_options file_time_type u8path absolute canonical weakly_canonical relative proximate copy_file copy_symlink create_directory create_directories create_hard_link create_symlink create_directory_symlink current_path exists equivalent file_size hard_link_count last_write_time permissions read_symlink remove_all rename resize_file space status symlink_status temp_directory_path is_block_file is_character_file is_directory is_fifo is_other is_regular_file is_socket is_symlink status_known atomic_char8_t atomic_signed_lock_free atomic_unsigned_lock_free atomic_wait atomic_wait_explicit atomic_notify_one atomic_notify_all atomic_flag_test atomic_flag_test_explicit atomic_flag_test_and_set atomic_flag_test_and_set_explicit atomic_flag_clear atomic_flag_clear_explicit atomic_flag_wait atomic_flag_wait_explicit atomic_flag_notify_one atomic_flag_notify_all kill_dependency atomic_thread_fence atomic_signal_fence this_thread thread jthread get_id sleep_for sleep_until stop_token stop_source stop_callback nostopstate_t nostopstate mutex timed_mutex recursive_mutex recursive_timed_mutex lock_guard unique_lock scoped_lock defer_lock_t try_to_lock_t adopt_lock_t once_flag defer_lock try_to_lock adopt_lock try_lock lock call_once shared_mutex shared_timed_mutex shared_lock promise packaged_task future shared_future launch future_status future_error future_errc async future_category conditional_variable conditional_variable_any cv_status notify_all_at_thread_exit counting_semaphore binary_semaphore latch barrier getline
  162.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement