Comments (5)
@pataei -- compile-time-known expressions are supported as type widths as long as you enclose them in parentheses. See Section 7.1.6.2 in the spec.
from p4-spec.
it should be a compile-time known value in the spec.
from p4-spec.
To double check my understanding, as an example, so there isn't anywhere in P4 that allows only bit<4>
and not bit<(2+2)>
, right?
from p4-spec.
These two should be fully equivalent and can be used in the same contexts. See also #1213
from p4-spec.
Closing this after the merge.
from p4-spec.
Related Issues (20)
- @optional annotation wording is confusing HOT 1
- Add expression to represent an invalid header_union value HOT 3
- Compiler should not expand stack copying in parsers
- The spec for header union operations seems incomplete HOT 7
- Loose description of implicit cast HOT 4
- There is no section on "operations on extern objects" HOT 4
- Should switch statements and select expressions be unified? HOT 3
- Sum QoS throughout HOT 3
- Include no-op casts (t -> t) in list of explicit casts HOT 1
- Allow easier casting of serializable enum to a different bit width HOT 5
- Original source of editable figures in the language spec? HOT 3
- Rationale for allowing 0-width type `bit<0>` ? HOT 6
- Confusing note about `action_run` switch HOT 4
- Introduce compile-time bounded for loops and if statements inside of `entries` table property HOT 16
- Should it be legal to have a reference of an extern type name within the definition of that extern? HOT 7
- All spec links from p4.org are broken HOT 2
- Add dynamic array to P4 HOT 13
- Streaming the payload HOT 1
- Language for specifying P4_16 architectures HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from p4-spec.