| /arkcompiler/runtime_core/static_core/plugins/ets/doc/spec/ |
| D | 18_annotations.rst | 18 An *annotation* is a special language element that changes the semantics of 21 The example below illustrates the declaring and using of an annotation: 26 // Annotation declaration: 31 // Annotation use: 35 The annotation *ClassAuthor* in the example above adds meta information to 38 An annotation must be placed immediately before the declaration it is applied to. 39 An annotation can include arguments as in the example above. 41 For an annotation to be used, the name of the annotation must be prefixed with 51 A :index:`compile-time error` occurs if the annotation name is not accessible 52 at the place of usage. An annotation declaration can be exported and used in [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/doc/annotations/ |
| D | annotations.rst | 16 An *annotation* is a special language element that changes the semantics of 19 The example below illustrates the declaring and using of an annotation: 24 // Annotation declaration: 29 // Annotation use: 33 The annotation *ClassAuthor* in the example above adds meta information to 36 An annotation must be placed immediately before the declaration it is applied to. 37 The annotation usage can include arguments as in the example above. 39 For an annotation to be used, its name must be prefixed with the symbol ``@`` 49 A compile-time error occurs if the annotation 50 name is not accessible at the place of usage. An annotation declaration can be [all …]
|
| D | anno2.txt | 24 Such annotation will be used by the compiler. 27 As an example of such annotation, the annotation ``@Deprecated`` 37 The annotation ``@Deprecated`` indicates that the annotated declaration is 46 The annotation ``@Deprecated`` has no argument. 70 denotes the plugin name of the annotation. 75 annotation: 93 - Does plugin define syntax of annotation usage syntax?
|
| /arkcompiler/ets_frontend/ets2panda/linter/test/ |
| D | sendable_explicit_field_type.ts.json | 386 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 393 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 400 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 407 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 414 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 421 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 428 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 442 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 449 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" 456 … "rule": "Field in sendable class must have type annotation (arkts-sendable-explicit-field-type)" [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/assembler/extension/ |
| D | metadata.yaml | 49 - name: annotation 62 - name: annotation.type 71 - name: annotation.class 80 - name: annotation.id 89 - name: annotation.element.type 108 - value: annotation 116 - name: annotation.element.array.component.type 134 - value: annotation 141 - name: annotation.element.name 150 - name: annotation.element.value
|
| D | ets_meta.h | 27 return attribute == "ets.annotation.class"; in IsAnnotationRecordAttribute() 32 return attribute == "ets.annotation.id"; in IsAnnotationIdAttribute() 37 return attribute == "ets.annotation.element.type"; in IsAnnotationElementTypeAttribute() 42 return attribute == "ets.annotation.element.array.component.type"; in IsAnnotationElementArrayComponentTypeAttribute() 47 return attribute == "ets.annotation.element.name"; in IsAnnotationElementNameAttribute() 52 return attribute == "ets.annotation.element.value"; in IsAnnotationElementValueAttribute() 80 auto type = GetAttributeValue("ets.annotation.type"); in IsRuntimeAnnotation() 90 auto type = GetAttributeValue("ets.annotation.type"); in IsTypeAnnotation()
|
| /arkcompiler/runtime_core/docs/ |
| D | assembly_format.md | 81 * All keys are unique within a single annotation list. 160 | `java.annotation` | Used to specify that the record represents Java annotation. | 161 | `java.annotation.type` | Used to specify type of annotation. Possible values: `class`, `runtime`.… 162 …va.annotation.class` | Used to specify annotation class. Allowed multiple definitions. Value is th… 163 …annotation.id` | Used to specify annotation id. Annotations with id are used as values of other an… 164 …annotation.element.name` | Used to specify name of the annotation element. `java.annotation.class`… 165 …annotation.element.type` | Used to specify type of the annotation element. `java.annotation.elemen… 166 …annotation.element.array.component.type` | Used to specify component type of the array annotation … 167 ….annotation.element.value` | Used to specify value of the annotation element. Allowed multiple def… 183 .record A1 <java.annotation, java.annotation.type=runtime> {} [all …]
|
| D | file_format.md | 179 | `ACC_ANNOTATION` | `0x2000` | Declared as an annotation type. | 294 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 295 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 296 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 297 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 363 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 366 …ANNOTATION` | `0x06` | `>=0` | `uint8_t[4]` | Data represents the offset to… 368 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 369 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 405 …annotation of the class. The tag may be repeated in case the class has several annotations. The of… [all …]
|
| /arkcompiler/runtime_core/assembler/tests/ |
| D | ecmascript_meta_test.cpp | 44 std::optional<pandasm::Metadata::Error> result2 = rmd.SetAttribute("ecmascript.annotation"); 50 …std::optional<pandasm::Metadata::Error> result4 = rmd.SetAttributeValue("ecmascript.annotation", "… 52 EXPECT_EQ(result4->GetMessage(), "Attribute 'ecmascript.annotation' must not have a value"); 59 std::optional<pandasm::Metadata::Error> result6 = rmd.SetAttribute("ecmascript.annotation"); 61 EXPECT_EQ(result6->GetMessage(), "Attribute 'ecmascript.annotation' already defined"); 78 rmd.SetAttribute("ecmascript.annotation"); 81 EXPECT_TRUE(rmd.GetAttribute("ecmascript.annotation")); 87 rmd.RemoveAttribute("ecmascript.annotation"); 88 EXPECT_FALSE(rmd.GetAttribute("ecmascript.annotation")); 97 rmd.SetAttribute("ecmascript.annotation"); [all …]
|
| /arkcompiler/runtime_core/plugins/ecmascript/tests/ |
| D | ecmascript_meta_test.cpp | 33 std::optional<pandasm::Metadata::Error> result2 = rmd.SetAttribute("ecmascript.annotation"); 39 …std::optional<pandasm::Metadata::Error> result4 = rmd.SetAttributeValue("ecmascript.annotation", "… 41 ASSERT_EQ(result4->GetMessage(), "Attribute 'ecmascript.annotation' must not have a value"); 48 std::optional<pandasm::Metadata::Error> result6 = rmd.SetAttribute("ecmascript.annotation"); 50 ASSERT_EQ(result6->GetMessage(), "Attribute 'ecmascript.annotation' already defined"); 58 rmd.SetAttribute("ecmascript.annotation"); 61 ASSERT_TRUE(rmd.GetAttribute("ecmascript.annotation")); 67 rmd.RemoveAttribute("ecmascript.annotation"); 68 ASSERT_FALSE(rmd.GetAttribute("ecmascript.annotation"));
|
| /arkcompiler/runtime_core/assembler/ |
| D | meta.cpp | 56 {"class", VType::RECORD}, {"enum", VType::ENUM}, {"annotation", VType::ANNOTATION}, in GetType() 198 case Value::Type::ANNOTATION: { 201 … return Unexpected(Metadata::Error("Unknown annotation id", Metadata::Error::Type::INVALID_VALUE)); 205 return ScalarValue::Create<Value::Type::ANNOTATION>(*annotation_value); 241 "'. Annotation element isn't completely defined", in Store() 257 "'. Annotation element isn't completely defined", in MeetExpRecordAttribute() 271 "'. Annotation record attribute must be defined first", in MeetExpIdAttribute() 277 "'. Annotation id attribute already defined", in MeetExpIdAttribute() 291 "'. Annotation record attribute must be defined first", in MeetExpElementNameAttribute() 297 "'. Previous annotation element isn't defined completely", in MeetExpElementNameAttribute() [all …]
|
| /arkcompiler/runtime_core/static_core/assembler/ |
| D | meta.cpp | 56 {"record", VType::RECORD}, {"enum", VType::ENUM}, {"annotation", VType::ANNOTATION}, in GetType() 199 case Value::Type::ANNOTATION: { 202 … return Unexpected(Metadata::Error("Unknown annotation id", Metadata::Error::Type::INVALID_VALUE)); 206 return ScalarValue::Create<Value::Type::ANNOTATION>(*annotationValue); 241 "'. Annotation element isn't completely defined", in Store() 257 "'. Annotation element isn't completely defined", in MeetExpRecordAttribute() 271 "'. Annotation record attribute must be defined first", in MeetExpIdAttribute() 277 "'. Annotation id attribute already defined", in MeetExpIdAttribute() 291 "'. Annotation record attribute must be defined first", in MeetExpElementNameAttribute() 297 "'. Previous annotation element isn't defined completely", in MeetExpElementNameAttribute() [all …]
|
| /arkcompiler/runtime_core/static_core/plugins/ets/disassembler/ |
| D | disasm_ets_plugin.cpp | 99 record->metadata->SetAttribute("ets.annotation"); in SetETSAttributes() 233 // 2 last characters are '[' & ']' if annotation is an array in EnumerateAnnotations() 243 if (isArray && elemCompType == "annotation") { in EnumerateAnnotations() 247 annList.push_back({"ets.annotation.type", type}); in EnumerateAnnotations() 250 annList.push_back({"ets.annotation.class", className}); in EnumerateAnnotations() 252 annList.push_back({"ets.annotation.id", "id_" + std::to_string(annotationId.GetOffset())}); in EnumerateAnnotations() 253 …annList.push_back({"ets.annotation.element.name", StringDataToString(file_->GetStringData(elemName… in EnumerateAnnotations() 257 annList.push_back({"ets.annotation.element.type", elemType}); in EnumerateAnnotations() 258 annList.push_back({"ets.annotation.element.array.component.type", elemCompType}); in EnumerateAnnotations() 262 …annList.push_back({"ets.annotation.element.value", ArrayValueToString(values, elemCompType, idx)}); in EnumerateAnnotations() [all …]
|
| /arkcompiler/runtime_core/abc2program/ |
| D | abc_method_processor.cpp | 138 for (auto annotation : function_.metadata->GetAnnotations()) { in FillSlotsNum() local 139 if (annotation.GetName() == SLOT_NUMBER_RECORD_NAME && !annotation.GetElements().empty()) { in FillSlotsNum() 140 … uint32_t slots_num = annotation.GetElements()[0].GetValue()->GetAsScalar()->GetValue<uint32_t>(); in FillSlotsNum() 148 for (auto annotation : function_.metadata->GetAnnotations()) { in FillConcurrentModuleRequests() local 149 if (annotation.GetName() != CONCURRENT_MODULE_REQUEST_RECORD_NAME) { in FillConcurrentModuleRequests() 152 for (auto &elem : annotation.GetElements()) { in FillConcurrentModuleRequests()
|
| /arkcompiler/runtime_core/disassembler/tests/ |
| D | disassembler_annotations_test.cpp | 24 static const std::string MODULE_REQUEST_FILE_NAME = GRAPH_TEST_ABC_DIR "module-requests-annotation-… 25 static const std::string SLOT_NUMBER_FILE_NAME = GRAPH_TEST_ABC_DIR "slot-number-annotation.abc"; 48 * @tc.desc: get module request annotation of abc file. 54 static const std::string METHOD_NAME = "module-requests-annotation-import.#*#funcD"; 66 * @tc.desc: get solt number annotation of abc file.
|
| /arkcompiler/ets_frontend/ets2panda/ir/ |
| D | expression.cpp | 24 if (auto *const annotation = other.TypeAnnotation(); annotation != nullptr) { in AnnotatedExpression() local 25 SetTsTypeAnnotation(annotation->Clone(allocator, this)->AsTypeNode()); in AnnotatedExpression()
|
| /arkcompiler/runtime_core/static_core/docs/ |
| D | file_format.md | 180 | `ACC_ANNOTATION` | `0x2000` | Declared as an annotation type. | 295 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 296 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 297 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 298 …annotation of the field. The tag may be repeated in case the field has several annotations. The of… 364 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 367 …ANNOTATION` | `0x06` | `>=0` | `uint8_t[4]` | Data represents the offset to… 369 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 370 …annotation of the method. The tag may be repeated in case the method has several annotations. The … 407 …annotation of the class. The tag may be repeated in case the class has several annotations. The of… [all …]
|
| /arkcompiler/ets_frontend/ets2panda/linter/docs/rules/ |
| D | recipe79.md | 1 # Type annotation in catch clause is not supported 7 In TypeScript, catch clause variable type annotation must be ``any`` or ``unknown``
|
| /arkcompiler/runtime_core/assembler/extensions/ |
| D | ecmascript_meta.cpp | 22 if (attribute == "ecmascript.annotation") { in Validate() 24 return Error("Attribute 'ecmascript.annotation' already defined", in Validate() 49 if (attribute == "ecmascript.annotation") { in Validate() 50 return Error("Attribute 'ecmascript.annotation' must not have a value", in Validate() 92 if (attribute == "ecmascript.annotation") { in SetFlags() 105 if (attribute == "ecmascript.annotation") { in RemoveFlags()
|
| /arkcompiler/ets_frontend/ets2panda/test/runtime/ets/annotation_tests/ |
| D | AnnotationNoNeedToSetProperties01.sts | 16 // Annotation declaretion: 21 // Annotation use:
|
| D | Muti-AnnotationsDefineAndUseForClass.sts | 16 // Annotation declaretion: 25 // Annotation use:
|
| D | AnnotationsDefineAndUseForClass.sts | 16 // Annotation declaretion: 21 // Annotation use:
|
| D | AnnotationForFunction02.sts | 16 // Annotation declaretion: 21 // Annotation use:
|
| D | AnnotationForFunction01.sts | 16 // Annotation declaretion: 21 // Annotation use:
|
| D | AnnotationsFieldType01.sts | 16 // Annotation declaretion: 23 // Annotation use:
|