From f98a2d5e0131f47de30c422fd69ca067453f92e0 Mon Sep 17 00:00:00 2001 From: Vitor Santos Costa Date: Thu, 17 Jan 2013 14:00:12 +0000 Subject: [PATCH] fix unbound throw (obs from Paualo Moura). --- pl/boot.yap | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pl/boot.yap b/pl/boot.yap index aad4dddf7..2d2f6074f 100755 --- a/pl/boot.yap +++ b/pl/boot.yap @@ -1194,8 +1194,12 @@ throw(_Ball) :- !, '$jump_env_and_store_ball'(Ball). throw(Ball) :- + ( var(Ball) -> + '$do_error'(instantiation_error,throw(Ball)) + ; % get current jump point - '$jump_env_and_store_ball'(Ball). + '$jump_env_and_store_ball'(Ball) + ). % just create a choice-point