[armedbear-cvs] r11968 - trunk/abcl/src/org/armedbear/lisp

Erik Huelsmann ehuelsmann at common-lisp.net
Sun May 31 15:17:26 UTC 2009


Author: ehuelsmann
Date: Sun May 31 11:17:24 2009
New Revision: 11968

Log:
More type assertion functions (checkXXXX()).

Modified:
   trunk/abcl/src/org/armedbear/lisp/Lisp.java

Modified: trunk/abcl/src/org/armedbear/lisp/Lisp.java
==============================================================================
--- trunk/abcl/src/org/armedbear/lisp/Lisp.java	(original)
+++ trunk/abcl/src/org/armedbear/lisp/Lisp.java	Sun May 31 11:17:24 2009
@@ -845,6 +845,25 @@
         type_error(obj, Symbol.VECTOR);
   }
 
+  public static final DoubleFloat checkDoubleFloat(LispObject obj)
+    throws ConditionThrowable
+  {
+          if (obj instanceof DoubleFloat)
+                  return (DoubleFloat) obj;
+          return (DoubleFloat)// Not reached.
+            type_error(obj, Symbol.DOUBLE_FLOAT);
+  }
+
+  public static final SingleFloat checkSingleFloat(LispObject obj)
+    throws ConditionThrowable
+  {
+          if (obj instanceof SingleFloat)
+                  return (SingleFloat) obj;
+          return (SingleFloat)// Not reached.
+            type_error(obj, Symbol.SINGLE_FLOAT);
+  }
+
+
   static
   {
     // ### *gensym-counter*




More information about the armedbear-cvs mailing list