p4lang / p4c-bm

Generates the JSON configuration for the behavioral-model (bmv2), as well as the C/C++ PD code
Apache License 2.0
24 stars 29 forks source link

Fail compilation if P4 program includes metadata initializer #97

Closed antoninbas closed 6 years ago

antoninbas commented 6 years ago

This is a P4_14 feature which is not supported directly by bmv2. Rather than trying to emit JSON "code" for it (e.g. with set_metadata calls in the parser), we reject the program.

codecov-io commented 6 years ago

Codecov Report

Merging #97 into master will increase coverage by <.01%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master      #97      +/-   ##
==========================================
+ Coverage    97.1%   97.11%   +<.01%     
==========================================
  Files          10       10              
  Lines        1693     1696       +3     
==========================================
+ Hits         1644     1647       +3     
  Misses         49       49
Impacted Files Coverage Δ
p4c_bm/gen_json.py 98.05% <100%> (ø) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update faca3fa...53feac3. Read the comment docs.