Closed thantry closed 7 years ago
Try getting a copy of this file: https://github.com/jafingerhut/p4lang-tests/blob/master/v1.0.3/switch-orig/primitives.json
Then add the command line option "--primitives primitives.json" to your compilation command line.
Thanks! Any reason (given that is part of the standard language) to not directly add it to: https://github.com/p4lang/p4-hlir/blob/master/p4_hlir/frontend/primitives.json and merge to master?
I don't know the history here. Perhaps someone else can answer that.
there's no reason for not having support really; these primitives were just added later to the spec i'll update the primitives.json file in this repo
It appears that these primitives should be allowed in actions by P4-14 (see page #41) ,
https://p4lang.github.io/p4-spec/p4-14/v1.0.4/tex/p4.pdf
but don't seem to be supported by the frontend compiler?
Also, it would be nice for the language to allow for these (value1, value2) to also include control plane args, in addition to immediates & fields.