wiki:BuiltInConditions

Built-in Conditions

ABCL distinguishes built-in conditions which it can easily use from the Primitives inside Java and "other" conditions - called Custom Conditions - which the ABCL user defines inside the Lisp environment.

The difference

There is one major difference between built-in conditions and custom conditions:

  • built-in conditions have classes inheriting from the org.armedbear.lisp.Condition class
  • custom conditions are -in the java world- represented using the org.armedbear.lisp.StandardObject? class

Built-in conditions can simply be instantiated in Java using the new operator.

Instantiation of built-in conditions from Lisp

To find the full list of Java classes which mirror a Lisp condition, have a look at make_condition.java. This file is being used from clos.lisp to create conditions in the MAKE-CONDITION function. When the function fails to match the condition class passed to it (ie. it returns NIL), it tries to instantiate an object of class StandardObject?.

Last modified 9 years ago Last modified on 10/26/08 19:40:09