@@ -65,6 +65,12 @@ open class P4ValueBase<T: P4Type>: P4Value {
|
||||
}
|
||||
}
|
||||
|
||||
extension P4ValueBase: EvaluatableExpression {
|
||||
public func evaluate(execution: ProgramExecution) -> Result<P4Value> {
|
||||
return .Ok(self)
|
||||
}
|
||||
}
|
||||
|
||||
/// The type for a P4 struct
|
||||
public struct P4Struct: P4Type {
|
||||
public let name: String
|
||||
@@ -122,6 +128,7 @@ public class P4BooleanValue: P4ValueBase<P4Boolean> {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/// A P4 int type
|
||||
public struct P4Int: P4Type {
|
||||
public static func create() -> any P4Type {
|
||||
|
||||
Reference in New Issue
Block a user