We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 741186c commit 9afffeeCopy full SHA for 9afffee
lang/cpp26/reflection.md
@@ -228,11 +228,11 @@ struct [[=1]] Annotated {
228
アノテーションの式は構造的型でなければならない。アノテーションの取得には[`annotations_of()`](/reference/meta/annotations_of.md)や[`annotations_of_with_type()`](/reference/meta/annotations_of_with_type.md)メタ関数を使用する。
229
230
```cpp
231
-struct Name { std::string_view value; };
+struct Name { const char* value; };
232
233
-struct [[=Name{"点"}]] Point {
234
- [[=Name{"x座標"}]] int x;
235
- [[=Name{"y座標"}]] int y;
+struct [[=Name{std::define_static_string("点")}]] Point {
+ [[=Name{std::define_static_string("x座標")}]] int x;
+ [[=Name{std::define_static_string("y座標")}]] int y;
236
};
237
238
// メンバのアノテーションを取得
0 commit comments