|
@@ -242,10 +242,13 @@ public class LispElement {
|
|
|
* @return
|
|
|
*/
|
|
|
public static LispElement generate(Object elt) {
|
|
|
- if(elt.getClass() == LispElement.class) {
|
|
|
- return (LispElement) elt;
|
|
|
+ if(elt == null) {
|
|
|
+ return new LispElement(null);
|
|
|
}
|
|
|
- if(elt.getClass() == Integer.class) {
|
|
|
+ else if(elt.getClass() == LispElement.class) {
|
|
|
+ return (LispElement) elt;
|
|
|
+ }
|
|
|
+ else if(elt.getClass() == Integer.class) {
|
|
|
elt = BigInteger.valueOf((Integer) elt);
|
|
|
}
|
|
|
else if(elt.getClass() == Boolean.class) {
|