Binary Expression in FIDL

Skip to first unread message

Swami Dhyan Anurag

Sep 4, 2020, 2:48:51 PM9/4/20
to Franca

I am trying to write something as below in FILD:
enumeration ABC {
ABC_NOK = 0x0000
ABC_OK = (0x020 | 0x0022)
Basically trying to use OR expression in enumeration but generator keeps giving error:
Error: Core validation: missing ')' at 'x020'
Error: Core validation: mismatched input '|' expecting '}' 
Error: Core validation: no viable alternative at input 'enumeration'

I will appreciate any pointers.


Klaus Birken

Sep 5, 2020, 2:54:46 PM9/5/20
to Franca
Hi Anurag,

Franca IDL doesn't support bitwise operations like "|" or "&". The rationale behind this is to not encourage bit-operations when specifying interfaces. You could create an issue in order to document your requirement, but at this point in time it is quite unlikely that it will be added without further users requesting the same extension. We are trying to keep the IDL as stable as possible, in order to avoid requiring changes in downstream tools using Franca IDL as input.

Best regards,

Swami Dhyan Anurag

Sep 5, 2020, 3:04:17 PM9/5/20
to Klaus Birken, Franca
Thank you Klaus for clarification.

I will manually fill the values for eums but yes it is way too much of manual work. Imagine creating 100s of vehicle property IDs which themselves are combinations of subcategories such as 

I will create  issue order hoping it help someone in future, in case needed.

Swami Anurag


You received this message because you are subscribed to a topic in the Google Groups "Franca" group.

To unsubscribe from this topic, visit

To unsubscribe from this group and all its topics, send an email to

To view this discussion on the web visit

swami dhyan anurag
Reply all
Reply to author
0 new messages