I think that Sven Siorpaes wrote:
I encountered a problem with the test function used in a rule within a
module.
Has there been any changes working with modules?
Hi Sven,
Note that Jess's reserved symbols are case sensitive, so the symbol true
is not the same as the correct one TRUE -- p.43 of JIA makes this
important distinction. However, changing just that in your code did not fix
the problem. I tried different versions of your code, and the (test) CE and
auto-focus work fine. I verified that your code does indeed work in version
6.1p7, so I'll escalate the issue to Ernest when he returns from vacation --
could be a regression.
In the meantime, you can always use an equals constraint inside your LHS
patterns to do exactly what a test CE does.
For example,
(defrule TEST::testfunction
(declare (auto-focus TRUE))
;; This is pattern ...
(foo (x ?x) (y ?y))
(test ( ?y ?x))
;; is equivalent to this pattern
;; (foo (x ?x) (y ?y:( ?y ?x))
=
(printout t Test successful))
Cheers,
Jason
--
Jason Morris - Assistant Moderator
Jess Listserver - [EMAIL PROTECTED]
email: [EMAIL PROTECTED]
www.morristechnicalsolutions.com
fax/phone: 503.692.1088
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]