Skip to content

Support verifying specifications using multiple triggers with the same name #74

Open
@RyanGlScott

Description

@RyanGlScott

Now that Copilot-Language/copilot#572 has landed, a copilot-c99–generated trigger can fire multiple times in a single time step. We will need to update copilot-verifier to account for this, as the verifier currently assumes that a trigger can only fire at most once in a single time step:

-- Assert that the trigger functions were called exactly once iff the
-- associated guard condition was true.
-- See Note [Global variables for trigger functions].
forM_ triggerGlobals $ \(nm, gv, guard) ->
do expectedCount <- liftIO $ do
one <- natLit sym 1
zero <- natLit sym 0
natIte sym guard one zero
actualCount <- readGlobal gv
eq <- liftIO $ natEq sym expectedCount actualCount

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions