Skip to content
Snippets Groups Projects
Commit e3d91f4e authored by Mick Jordan's avatar Mick Jordan
Browse files

fix for AsFunction

parent a8149e79
Branches
No related tags found
No related merge requests found
...@@ -77,6 +77,8 @@ public abstract class AsFunction extends RBuiltinNode { ...@@ -77,6 +77,8 @@ public abstract class AsFunction extends RBuiltinNode {
defaultValue = null; defaultValue = null;
} else if (arg == RNull.instance) { } else if (arg == RNull.instance) {
defaultValue = ConstantNode.create(RNull.instance); defaultValue = ConstantNode.create(RNull.instance);
} else if (arg instanceof RLanguage && ((RLanguage) arg).getRep() instanceof ConstantNode) {
defaultValue = (ConstantNode) ((RLanguage) arg).getRep();
} else { } else {
throw RInternalError.unimplemented(); throw RInternalError.unimplemented();
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment