C++相談室 part7
■ このスレッドは過去ログ倉庫に格納されています
0227デフォルトの名無しさん
NGNG14.3.2 Template non-type arguments
1- A template-argument for a non-type, non-template template-parameter shall be one of:
以下略。
an integral constant-expression of integral or enumeration type に該当しそうな気もするんだけど、しないのかもしんない。ポインタは integral ではないのかな。ないのかも。
>>226
>つーか Hoge<"aaaa"> とかすらコンパイルエラーになると
それは、はっきり書いてある。
-2- A string literal is not an acceptable template-argument because a string literal is an object with internal linkage.
引用元 www.kuzbass.ru/docs/isocpp/template.html
■ このスレッドは過去ログ倉庫に格納されています