-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do a holistic renaming of the various predicates #22
Comments
I also wondered about Maybe, we can even define an For the core |
I would argue that our crypto predicates (e.g., dolev-yao-star-extrinsic/src/core/DY.Core.Bytes.fst Lines 328 to 355 in 452210f
Specifically, lines 339-355. Packaging an invariant with its |
@qaphla Good catch. Indeed, it looks like we could renaming everything "invariant" except the "crypto predicates". @cwaldm To use a generic "predicate that is preserved by trace extension" type, we would need to uncurry all the predicates, e.g. the state invariant would become |
As noticed by @cwaldm when discussing on #19, we have many predicate types and it would be nice to have some consistency between them.
I think in general the types are named
foo_predicate
, and the predicate is named either:bar_pred
,baz_pred
when there are several sub-predicatespred
when there is only one predicateThere is also the question of
predicate
vsinvariant
. I think I tried to usepredicate
for types that actually contain the predicates, andinvariant
for things that are more collection of predicates.In
Core
:dolev-yao-star-extrinsic/src/core/DY.Core.Bytes.fst
Lines 237 to 267 in 452210f
dolev-yao-star-extrinsic/src/core/DY.Core.Trace.Invariant.fst
Lines 30 to 50 in 452210f
dolev-yao-star-extrinsic/src/core/DY.Core.Trace.Invariant.fst
Lines 54 to 58 in 452210f
dolev-yao-star-extrinsic/src/core/DY.Core.Trace.Invariant.fst
Lines 66 to 70 in 452210f
In
DY.Lib.Event
:dolev-yao-star-extrinsic/src/lib/event/DY.Lib.Event.Typed.fst
Lines 41 to 42 in 452210f
In
DY.Lib.State
:dolev-yao-star-extrinsic/src/lib/state/DY.Lib.State.Tagged.fst
Lines 25 to 41 in 452210f
dolev-yao-star-extrinsic/src/lib/state/DY.Lib.State.Typed.fst
Lines 22 to 38 in 452210f
dolev-yao-star-extrinsic/src/lib/state/DY.Lib.State.Map.fst
Lines 27 to 37 in 452210f
In particular, @cwaldm proposed to rename
state_predicate
intoglobal_state_predicate
to oppose it tolocal_state_predicate
. I would rather keep the names of DY.Core agnostic to what is done in DY.Lib and keep the name as-is, but add some documentation abovestate_predicate
to explain that it is a global predicate and that separating it into several local state predicates is done in DY.Lib.The text was updated successfully, but these errors were encountered: