Skip to content

Commit

Permalink
Avoid const decl from included files being declared twice (#49)
Browse files Browse the repository at this point in the history
  • Loading branch information
MiguelCompany authored May 27, 2019
2 parents 3e85b3b + 4f61be9 commit 906c966
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/java/com/eprosima/fastcdr/idl/templates/TypesHeader.stg
Original file line number Diff line number Diff line change
Expand Up @@ -193,9 +193,7 @@ param_list(parameters) ::= <<>>

param(parameter) ::= <<>>

const_decl(ctx, parent, const) ::= <<
$if(const.parent)$$if(const.parent.isInterface)$static $endif$$endif$const $const.typeCode.cppTypename$ $const.name$$if(!const.parent)$ = $const.value$$elseif(!const.parent.isInterface)$ = $const.value$$elseif(!const.typeCode.isType_5)$$if(!const.typeCode.isType_6)$ = $const.value$$endif$$endif$;
>>
const_decl(ctx, parent, const) ::= <<$if(ctx.inScopedFile)$$if(const.parent)$$if(const.parent.isInterface)$static $endif$$endif$const $const.typeCode.cppTypename$ $const.name$$if(!const.parent)$ = $const.value$$elseif(!const.parent.isInterface)$ = $const.value$$elseif(!const.typeCode.isType_5)$$if(!const.typeCode.isType_6)$ = $const.value$$endif$$endif$;$endif$>>

typedef_decl(ctx, parent, typedefs) ::= <<
$typedefs : { typedef |typedef $typedef.typedefContentTypeCode.cppTypename$ $typedef.name$;}; separator="\n"$
Expand Down

0 comments on commit 906c966

Please sign in to comment.