Skip to content

CallListNode Modifier definition hacky #45

@d1m0

Description

@d1m0

Currently the CallListNode is defined as follows:

.type CallListNode = Node { id: id }
                  | Call { id: CallsiteType, target: CalleeType }
                  | Modifier { id: FunctionDefinitionId, idx: number, placeHolder: PlaceholderStatementId }
                  | BaseConstructor { mdc: ContractDefinitionId, baseIdx: number }

The Modifier branch actually serves 2 different purposes - for the case of a normal ModifierDefinition body, and also when are in the body of the actual function, we add an extra $Modifier(funId, -1, placeHolder) just to remember the exact PlaceholderStatement in the topmost modifier that we are in.

It might make sense to split Modifier into 2 branches.

(Also the printing logic for Modifier in Fact.fmt is fairly ugly)

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