diff options
author | John Ankarström <john@ankarstrom.se> | 2022-02-15 15:38:57 +0100 |
---|---|---|
committer | John Ankarström <john@ankarstrom.se> | 2022-02-15 15:38:57 +0100 |
commit | 09ec144a99f1234a37d04854bdfb81485540be97 (patch) | |
tree | ce3050a062a76dd12980b08ef36eb7ac35b7e6f8 /pl/atom_dcg.pl | |
parent | fed19b9942575e7c0360a0d77a3c544afdbaeb6c (diff) | |
download | EpisodeBrowser-09ec144a99f1234a37d04854bdfb81485540be97.tar.gz |
Put C code and Prolog code in separate directories.
Diffstat (limited to 'pl/atom_dcg.pl')
-rw-r--r-- | pl/atom_dcg.pl | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/pl/atom_dcg.pl b/pl/atom_dcg.pl new file mode 100644 index 0000000..74689d5 --- /dev/null +++ b/pl/atom_dcg.pl @@ -0,0 +1,11 @@ +:- module(atom_dcg, [atom_phrase/2]). + +:- meta_predicate atom_phrase(2, ?). + +atom_phrase(G, A) :- + ( var(A) + -> phrase(G, C), + atom_codes(A, C) + ; atom_codes(A, C), + phrase(G, C) + ). |