From 98daf1ebddcb84815aff2f61f05c0169f212e8d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADtor=20Santos=20Costa?= Date: Wed, 7 May 2014 09:35:57 +0100 Subject: [PATCH] bad call to style_checker. --- C/iopreds.c | 5 ++++- pl/checker.yap | 1 - 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/C/iopreds.c b/C/iopreds.c index fdd148fe7..c03156e5a 100755 --- a/C/iopreds.c +++ b/C/iopreds.c @@ -913,7 +913,10 @@ p_style_checker( USES_REGS1 ) Term h = HeadOfTerm( t ); t = TailOfTerm( t ); - if (IsAtomTerm(h)) { + if (IsVarTerm(h)) { + Yap_Error(INSTANTIATION_ERROR, t, "style_check/1"); + return (FALSE); + } if (IsAtomTerm(h)) { Atom at = AtomOfTerm( h ); if (at == AtomAtom) debugstatus.styleCheck |= LONGATOM_CHECK; else if (at == AtomSingleton) debugstatus.styleCheck |= SINGLETON_CHECK; diff --git a/pl/checker.yap b/pl/checker.yap index 925544e1c..1b3ed2bb6 100644 --- a/pl/checker.yap +++ b/pl/checker.yap @@ -137,7 +137,6 @@ style_check_(+charset) :- style_check_(-charset) :- '$style_checker'( [ -charset ] ). style_check_('?'(Info) ) :- - '$style_checker '( [ L ] ), lists:member( Style, [ singleton, discontiguous, multiple ] ), ( lists:member(Style, L ) -> Info = +Style ; Info = -Style ). style_check_([]).