Skip to content

Inconsistency between paper and library #58

@flip111

Description

@flip111

Paper page 5

analyzeAndRewriteFwdBody
:: ( CkpointMonad m -- Roll back speculative actions
, NonLocal n ) -- Extract non-local flow edges
=> FwdPass m n f -- Lattice, transfer, rewrite
-> [Label] -- Entry point(s)
-> Graph n C C -- Input graph
-> FactBase f -- Input fact(s)
-> m ( Graph n C C -- Result graph
, FactBase f ) -- ... and its facts

Again same but single line

analyzeAndRewriteFwdBody :: ( CkpointMonad m, NonLocal n ) => FwdPass m n f -> [Label] -> Graph n C C -> FactBase f -> m (Graph n C C, FactBase f )

library

analyzeAndRewriteFwdBody :: forall m n f entries. (CheckpointMonad m, NonLocal n, LabelsPtr entries) => FwdPass m n f -> entries -> Body n -> FactBase f -> m (Body n, FactBase f)

[Label] is type compatible with entries. But Graph n C C and Body are not type compatible. It's not a problem with the code though, the test case also shows that the library works. The paper is mostly clear but it's just not exactly the same. Test case uses a different function

analyzeAndRewriteFwd :: forall m n f e x entries. (CheckpointMonad m, NonLocal n, LabelsPtr entries) => FwdPass m n f -> MaybeC e entries -> Graph n e x -> Fact e f -> m (Graph n e x, FactBase f, MaybeO x f)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions