MCPcopy Index your code
hub / github.com/clojure/clojure / emit

Method emit

src/jvm/clojure/lang/Compiler.java:483–514  ·  view source on GitHub ↗
(C context, ObjExpr objx, GeneratorAdapter gen)

Source from the content-addressed store, hash-verified

481 }
482
483 public void emit(C context, ObjExpr objx, GeneratorAdapter gen){
484 objx.emitVar(gen, var);
485 if(isDynamic)
486 {
487 gen.push(isDynamic);
488 gen.invokeVirtual(VAR_TYPE, setDynamicMethod);
489 }
490 if(meta != null)
491 {
492 if (initProvided || true)//includesExplicitMetadata((MapExpr) meta))
493 {
494 gen.dup();
495 meta.emit(C.EXPRESSION, objx, gen);
496 gen.checkCast(IPERSISTENTMAP_TYPE);
497 gen.invokeVirtual(VAR_TYPE, setMetaMethod);
498 }
499 }
500 if(initProvided)
501 {
502 gen.dup();
503 if(init instanceof FnExpr)
504 {
505 ((FnExpr)init).emitForDefn(objx, gen);
506 }
507 else
508 init.emit(C.EXPRESSION, objx, gen);
509 gen.invokeVirtual(VAR_TYPE, bindRootMethod);
510 }
511
512 if(context == C.STATEMENT)
513 gen.pop();
514 }
515
516 public boolean hasJavaClass(){
517 return true;

Callers

nothing calls this directly

Calls 8

emitVarMethod · 0.80
invokeVirtualMethod · 0.80
dupMethod · 0.80
checkCastMethod · 0.80
emitForDefnMethod · 0.80
emitMethod · 0.65
popMethod · 0.65
pushMethod · 0.45

Tested by

no test coverage detected