diff options
author | Fred Hornsey <hornseyf@objectcomputing.com> | 2018-09-19 16:12:16 -0500 |
---|---|---|
committer | Fred Hornsey <hornseyf@objectcomputing.com> | 2018-09-19 16:12:16 -0500 |
commit | 1fdc730a5b27747a2f90500f836a1304e21a6f61 (patch) | |
tree | 086ffb2466dbe7ced8a0a996c7b756c4eb7267ff | |
parent | e552c6c73b3f7946e3a2de224ad341196ee2e3b9 (diff) | |
download | ATCD-1fdc730a5b27747a2f90500f836a1304e21a6f61.tar.gz |
tao_idl: Fix IDL version enum other small things
-rw-r--r-- | TAO/TAO_IDL/fe/idl.ll | 3 | ||||
-rw-r--r-- | TAO/TAO_IDL/fe/idl.ypp | 18 | ||||
-rw-r--r-- | TAO/TAO_IDL/include/ast_decl.h | 1 |
3 files changed, 12 insertions, 10 deletions
diff --git a/TAO/TAO_IDL/fe/idl.ll b/TAO/TAO_IDL/fe/idl.ll index 817051334be..fbc5ad7e337 100644 --- a/TAO/TAO_IDL/fe/idl.ll +++ b/TAO/TAO_IDL/fe/idl.ll @@ -204,6 +204,9 @@ oneway return IDL_ONEWAY; return IDL_SCOPE_DELIMITOR; } +@annotation return IDL_ANNOTATION_DECL; +@ return IDL_ANNOTATION_SYMBOL; + [a-ij-rs-zA-IJ-RS-Z_][a-ij-rs-zA-IJ-RS-Z0-9_]* { // Make sure that this identifier is not a C++ keyword. If it is, // prepend it with a _cxx_. Lookup in the perfect hash table for C++ diff --git a/TAO/TAO_IDL/fe/idl.ypp b/TAO/TAO_IDL/fe/idl.ypp index 8b57341f209..5f3461df675 100644 --- a/TAO/TAO_IDL/fe/idl.ypp +++ b/TAO/TAO_IDL/fe/idl.ypp @@ -281,6 +281,9 @@ AST_Expression::ExprType t_param_const_type = AST_Expression::EV_none; %token <wcval> IDL_WCHAR_LITERAL %token <wsval> IDL_WSTRING_LITERAL +%token IDL_ANNOTATION_DECL +%token IDL_ANNOTATION_SYMBOL + /* * These are production names: */ @@ -2351,14 +2354,9 @@ positive_int_expr : } ; -/* Annotations - TODO: actions - TODO: annotation_dcl and friends - */ - annotation_dcl - : "@annotation" IDENTIFIER '{' annotation_body '}' { - if (idl_global->idl_version_ >= IDL_VERSION_4_0) + : IDL_ANNOTATION_DECL IDENTIFIER '{' annotation_body '}' { + if (idl_global->idl_version_ >= IDL_VERSION_4) { ACE_DEBUG ((LM_WARNING, ACE_TEXT ("WARNING: in %C on line %d:\n") @@ -2400,7 +2398,7 @@ annotation_member_dcl annotation_member_type : const_type /* Also covers scope_name wanted by the spec grammer */ - | "any" /* supported by this compiler? */ + | any_type ; defaulted_annotation_member_dcl @@ -2414,7 +2412,7 @@ annotation_member annotations : annotations annotation_appl { - if (idl_global->idl_version_ < IDL_VERSION_4_0) + if (idl_global->idl_version_ < IDL_VERSION_4) { ACE_ERROR ((LM_ERROR, ACE_TEXT ("ERROR: in %C on line %d:\n") @@ -2431,7 +2429,7 @@ annotations ; annotation_appl - : '@' scoped_name annotation_appl_params_maybe + : IDL_ANNOTATION_SYMBOL scoped_name annotation_appl_params_maybe ; annotation_appl_params_maybe diff --git a/TAO/TAO_IDL/include/ast_decl.h b/TAO/TAO_IDL/include/ast_decl.h index 5517834723c..a30513bca60 100644 --- a/TAO/TAO_IDL/include/ast_decl.h +++ b/TAO/TAO_IDL/include/ast_decl.h @@ -169,6 +169,7 @@ public: , NT_mirror_port // Denotes a mirror port , NT_connector // Denotes a CCM connector , NT_param_holder // Denotes a template param placeholder + , NT_annotation // An application of an annotation }; AST_Decl (NodeType type, |