You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@thrift.apache.org by "James E. King, III (JIRA)" <ji...@apache.org> on 2017/08/30 19:28:00 UTC
[jira] [Updated] (THRIFT-4286) Composite Constants Defined by Other
Constants
[ https://issues.apache.org/jira/browse/THRIFT-4286?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
James E. King, III updated THRIFT-4286:
---------------------------------------
Component/s: Compiler (General)
> Composite Constants Defined by Other Constants
> ----------------------------------------------
>
> Key: THRIFT-4286
> URL: https://issues.apache.org/jira/browse/THRIFT-4286
> Project: Thrift
> Issue Type: New Feature
> Components: Compiler (General)
> Reporter: Merter Sualp
>
> We would like to define constants by using previously defined constants.
> *Example 1:*
> const string PREFIX = "prefix/path"
> const string SUFFIX = "suffix/path"
> const string CONCATENATION = PREFIX + "/" + SUFFIX
> // which will yield to prefix/path/suffix/path
> *Example 2:*
> const i32 MULTIPLICAND = 25
> const i32 MULTIPLIER = 4
> const i32 PRODUCT = MULTIPLICAND * MULTIPLIER
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)