Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
46 commits
Select commit Hold shift + click to select a range
dc89619
CWG2555 Ineffective redeclaration prevention for using-declarators
eisenwave Nov 9, 2025
37d12fd
CWG2677 Replacing union subobjects
eisenwave Nov 9, 2025
9e6cdd3
CWG2875 Missing support for round-tripping null pointer values throug…
eisenwave Nov 9, 2025
a9cc880
CWG2900 Deduction of non-type template arguments with placeholder types
eisenwave Nov 9, 2025
9d2bc91
CWG2929 Lifetime of trivially-destructible static or thread-local obj…
eisenwave Nov 9, 2025
c46d6e7
CWG2941 Lifetime extension for function-style cast to reference type
eisenwave Nov 9, 2025
560c6aa
CWG3001 Inconsistent restrictions for static_cast on pointers to out-…
tkoeppe Dec 13, 2025
bc34c21
CWG3002 Template parameter/argument confusion
eisenwave Nov 9, 2025
2006116
CWG3004 Pointer arithmetic on array of unknown bound
eisenwave Nov 9, 2025
f55bea9
CWG3008 Missing Annex C entry for void object declarations
eisenwave Nov 9, 2025
b265dd3
CWG3011 Parenthesized aggregate initialization for new-expressions
eisenwave Nov 9, 2025
45b325b
CWG3032 Template argument disambiguation
eisenwave Nov 9, 2025
e1e198f
CWG3055 Misleading body for surrogate call function
eisenwave Nov 9, 2025
7a1e977
CWG3056 Missing semicolons in grammar for type-requirement
eisenwave Nov 9, 2025
81ed76b
CWG3057 Ranking of derived-to-base conversions should ignore referenc…
eisenwave Nov 9, 2025
a6489fb
CWG3059 throw; in constant expressions
eisenwave Nov 9, 2025
abfffd1
CWG3060 Change in behavior for noexcept main
eisenwave Nov 9, 2025
f5b56ae
CWG3062 Overlapping specification of default template arguments
eisenwave Nov 9, 2025
16201fa
CWG3066 Declarative nested-name-specifier in explicit instantiation
eisenwave Nov 9, 2025
a7d1601
CWG3067 Array-to-pointer conversion with object type mismatch
eisenwave Nov 9, 2025
77b9c7f
CWG3070 Trivial assignment can skip member subobjects
eisenwave Nov 9, 2025
3c11d7e
CWG3071 Negative tuple_size in structured bindings
eisenwave Nov 9, 2025
41c5c55
CWG3072 Incorrect examples for lambda SFINAE
eisenwave Nov 9, 2025
68c6635
CWG3073 Dependence of R on T2 is unclear
eisenwave Nov 9, 2025
3243d8e
CWG3075 Unclear matching of import directive
eisenwave Nov 9, 2025
4fc3903
CWG3076 Remove unnecessary IFNDR for malformed header-name-tokens
eisenwave Nov 9, 2025
a4bc63f
CWG3077 Undesirable formation of import directive with string-literal
eisenwave Nov 9, 2025
3140e5f
CWG3078 Different treatment of #include pp-tokens and header-name-tokens
eisenwave Nov 9, 2025
5b61c71
CWG3079 Allow empty-declarations in anonymous unions
eisenwave Nov 9, 2025
ae227c7
CWG3080 Clarify kinds of permitted template template arguments
eisenwave Nov 9, 2025
73dcbe2
CWG3081 Require glvalue when splicing direct base class relationship
eisenwave Nov 9, 2025
c41620c
CWG3083 Remove redundant restrictions on class and enum definitions
eisenwave Nov 9, 2025
fb6d393
CWG3085 Apply restriction inside for-range-declaration
eisenwave Nov 9, 2025
5850cd5
CWG3086 Destringizing should consider all sorts of encoding-prefixes
eisenwave Nov 9, 2025
2c581e9
CWG3090 Internal linkage from header units
eisenwave Nov 9, 2025
aa9f285
CWG3091 Linking of translation units as sequences of tokens
eisenwave Nov 9, 2025
1968418
CWG3096 Value-dependence of size of structured binding pack with non-…
eisenwave Nov 9, 2025
dc9b135
CWG3097 Lambda expression introduces a scope
eisenwave Nov 9, 2025
441eeba
CWG3100 Destruction order for objects with static storage duration
eisenwave Nov 9, 2025
fa5bfc7
CWG3102 Update list of void contexts
eisenwave Nov 9, 2025
fa0e563
CWG3105 Consteval destructor through immediate escalation
eisenwave Nov 9, 2025
0312df9
CWG3106 Redundant exclusion of (non-existent) UCNs in r-char-sequences
eisenwave Nov 9, 2025
3800851
CWG3107 Misleading note "An alias template name is never deduced."
eisenwave Nov 9, 2025
a64ab84
CWG3111 Template parameter objects of array type
eisenwave Nov 9, 2025
ee16c7f
CWG3112 Introduce a term for C-style variadic functions
eisenwave Nov 9, 2025
5bfe790
CWG3116 First element of an array
eisenwave Nov 9, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
CWG3111 Template parameter objects of array type
  • Loading branch information
eisenwave authored and tkoeppe committed Dec 13, 2025
commit a64ab84f2952f5c593c34bb41913dff5e994ac43
4 changes: 4 additions & 0 deletions source/meta.tex
Original file line number Diff line number Diff line change
Expand Up @@ -4124,6 +4124,10 @@
\begin{codeblock}
if constexpr (is_annotation(@$R$@)) {
return @$C$@;
} else if constexpr (is_array_type(type_of(@$R$@))) {
return reflect_constant_array([: @$R$@ :]);
} else if constexpr (is_function_type(type_of(@$R$@))) {
return reflect_function([: @$R$@ :]);
} else {
return reflect_constant([: @$R$@ :]);
}
Expand Down
14 changes: 10 additions & 4 deletions source/templates.tex
Original file line number Diff line number Diff line change
Expand Up @@ -496,15 +496,21 @@
\end{itemize}

\pnum
Certain constructs refer to template parameter objects,
which are distinct objects with static storage duration and non-volatile const type.
No two such objects have template-argument-equivalent values\iref{temp.type}.
An \grammarterm{id-expression} naming
a constant template parameter of class type \tcode{T}
denotes a static storage duration object of type \tcode{const T},
known as a \defn{template parameter object},
which is template-argument-equivalent\iref{temp.type} to
denotes the template parameter object of type \tcode{const T},
which is template-argument-equivalent to
the corresponding template argument
after it has been converted
to the type of the template parameter\iref{temp.arg.nontype}.
No two template parameter objects are template-argument-equivalent.
\begin{note}
There can be template parameter objects of array type\iref{meta.define.static},
but such an object is never denoted by an \grammarterm{id-expression}
that names a constant template parameter.
\end{note}
\begin{note}
If an \grammarterm{id-expression} names
a non-reference constant template parameter,
Expand Down