Skip to content

-->> can produce non-steadfast code in the presence of cuts #5

@kamahen

Description

@kamahen

This comment by Richard O'Keefe discusses why the original implementation of DCGs used C/3 instead of pushing the unification into the head:
https://swi-prolog.iai.uni-bonn.narkive.com/cOnL0aGn/push-back-lists-on-dcg-rule-heads

It is possible that a cut in an EDCG body would violate this; whether it's important is not clear.

The implementation of ==>> uses '=/2instead of pushing the unification into the head; because==>>uses=>`, cuts are not likely in the body, so this is less of a problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions