Initial Array Access Implementation

Signed-off-by: Will Hawkins <hawkinsw@obs.cr>
This commit is contained in:
Will Hawkins
2026-03-13 09:41:04 -04:00
parent 1982fda677
commit 0b4db34177
10 changed files with 266 additions and 11 deletions
+12 -1
View File
@@ -17,10 +17,17 @@
open class ProgramExecution: CustomStringConvertible {
public var scopes: ValueScopes = ValueScopes()
let initialValues: ValueScopes?
var error: Error?
var debug: DebugLevel = DebugLevel.Error
public init() {}
public init() {
initialValues = .none
}
public init(withGlobalValues values: ValueScopes) {
initialValues = values
}
open var description: String {
return "Runtime:\nScopes: \(scopes)"
@@ -80,6 +87,10 @@ open class ProgramExecution: CustomStringConvertible {
new_pe.scopes = new_scopes
return new_pe
}
public func initial_values() -> ValueScopes? {
return self.initialValues
}
}
public typealias ValueScope = Scope<P4Value>