From f8972365f8ec783e6abf651184cfc86c122ced53 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADtor=20Santos=20Costa?= Date: Thu, 29 Mar 2012 22:32:56 +0100 Subject: [PATCH] fix phrase/3 --- pl/grammar.yap | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/pl/grammar.yap b/pl/grammar.yap index 39775ae31..debb5dc75 100644 --- a/pl/grammar.yap +++ b/pl/grammar.yap @@ -132,9 +132,6 @@ phrase(PhraseDef, WordList) :- phrase(PhraseDef, WordList, []). -phrase(_:[], S, S) :- !. -phrase(_:[H|T], S0, S) :- !, - lists:append([H|T], S, S0). phrase(P, S0, S) :- call(P, S0, S). @@ -142,6 +139,8 @@ phrase(P, S0, S) :- [](S, S). +[](H, T, S0, S) :- lists:append([H|T], S, S0). + '.'(H,T, S0, S) :- lists:append([H|T], S, S0).