}
public static void createReturn(EvaluationContext context,Expr e, InstList l) throws CompilerException {
if (context.returnInst == null) {
createConvert(context, e, context.fullyQualified(context.methodDef.returnType), l) ;
l.add(new Return(TypeCode.getType(context.methodDef.returnType))) ;
}
else {
final VarDecl varDecl = new VarDecl(context.methodDef.returnType,"$$ret$$",e);
final VarStack vars = context.decls.addLocalVar(context.getFileUnitInfo(),new FIFO<VarDecl>(varDecl));
EvaluationContext newContext = context.setVars(vars) ;
LValue v = newContext.getVar("$$ret$$") ;
makeInit(newContext,varDecl.init,v.getType(),l) ;
l.add(new Store(v)) ;
l.add(context.returnInst) ;
l.add(new Load(v)) ;
l.add(new Return(TypeCode.getType(context.methodDef.returnType))) ;
}
}