Changeset 3978
- Timestamp:
- 09/21/03 19:48:51 (20 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/j/src/org/armedbear/lisp/LispClass.java
r3976 r3978 3 3 * 4 4 * Copyright (C) 2003 Peter Graves 5 * $Id: LispClass.java,v 1.2 4 2003-09-21 19:32:34piso Exp $5 * $Id: LispClass.java,v 1.25 2003-09-21 19:48:51 piso Exp $ 6 6 * 7 7 * This program is free software; you can redistribute it and/or … … 44 44 protected final Symbol symbol; 45 45 private LispObject directSuperclasses; 46 private LispObject classPrece ndenceList;46 private LispObject classPrecedenceList = NIL; 47 47 48 48 protected LispClass(Symbol symbol) … … 81 81 public final LispObject getCPL() 82 82 { 83 return classPrece ndenceList;83 return classPrecedenceList; 84 84 } 85 85 … … 87 87 { 88 88 Debug.assertTrue(obj1 == this); 89 classPrece ndenceList = new Cons(obj1);89 classPrecedenceList = new Cons(obj1); 90 90 } 91 91 … … 93 93 { 94 94 Debug.assertTrue(obj1 == this); 95 classPrece ndenceList = list2(obj1, obj2);95 classPrecedenceList = list2(obj1, obj2); 96 96 } 97 97 … … 99 99 { 100 100 Debug.assertTrue(obj1 == this); 101 classPrece ndenceList = list3(obj1, obj2, obj3);101 classPrecedenceList = list3(obj1, obj2, obj3); 102 102 } 103 103 … … 106 106 { 107 107 Debug.assertTrue(obj1 == this); 108 classPrece ndenceList = list4(obj1, obj2, obj3, obj4);108 classPrecedenceList = list4(obj1, obj2, obj3, obj4); 109 109 } 110 110 … … 113 113 { 114 114 Debug.assertTrue(obj1 == this); 115 classPrece ndenceList = list5(obj1, obj2, obj3, obj4, obj5);115 classPrecedenceList = list5(obj1, obj2, obj3, obj4, obj5); 116 116 } 117 117 … … 120 120 { 121 121 Debug.assertTrue(obj1 == this); 122 classPrece ndenceList = list6(obj1, obj2, obj3, obj4, obj5, obj6);122 classPrecedenceList = list6(obj1, obj2, obj3, obj4, obj5, obj6); 123 123 } 124 124 … … 128 128 { 129 129 Debug.assertTrue(obj1 == this); 130 classPrece ndenceList = list7(obj1, obj2, obj3, obj4, obj5, obj6, obj7);130 classPrecedenceList = list7(obj1, obj2, obj3, obj4, obj5, obj6, obj7); 131 131 } 132 132 … … 190 190 }; 191 191 192 private static final Primitive1 CLASS_PRECEDENCE_LIST = 193 new Primitive1("class-precedence-list", PACKAGE_SYS, false) 194 { 195 public LispObject execute(LispObject arg) throws ConditionThrowable 196 { 197 if (arg instanceof LispClass) 198 return ((LispClass)arg).getCPL(); 199 throw new ConditionThrowable(new TypeError(arg, "class")); 200 } 201 }; 202 192 203 private static final Primitive1 CLASSP = 193 204 new Primitive1("classp", PACKAGE_SYS, false)
Note: See TracChangeset
for help on using the changeset viewer.