     #  os.name,os.arch,os.version,file.separator,path.separator,line.separator,
     #  user.name,user.home,user.dir     
     rs.push p_ref
+    )
+  'java/lang/System::setIn0(Ljava/io/InputStream;)V': ((rs) -> 
+    rs.push rs.curr_frame().locals[0] # move oref to the stack
+    rs.static_put {'class':'java/lang/System','sig':{'name':'in'}}
     )
 }
 

    if trapped_methods[sig]
      return @run_manually(runtime_state,trapped_methods[sig])
    if @access_flags.native
      if sig.indexOf('::registerNatives()V',1) >= 0  # we don't need to register native methods
        return @run_manually(runtime_state,(rs)->)
      throw "native method NYI: #{sig}" unless native_methods[sig]
      return @run_manually(runtime_state,native_methods[sig])
    # main eval loop: execute each opcode, using the pc to iterate through
    code = @get_code().opcodes
    while true
      cf = runtime_state.curr_frame()
      pc = runtime_state.curr_pc()
      op = code[pc]
      #console.log "#{padding}stack: [#{cf.stack}], local: [#{cf.locals}]"
      #console.log "#{padding}#{@name}:#{pc} => #{op.name}"
      op.execute runtime_state
      if op.name.match /.*return/
        s = runtime_state.meta_stack.pop().stack

trapped_methods = {
  'java/lang/System::setJavaLangAccess()V': (rs) -> #NOP
  'java/lang/System::loadLibrary(Ljava/lang/String;)V': (rs) -> console.log "warning: library loads are NYI"
  'java/lang/ThreadLocal::<clinit>()V': (rs) -> #NOP
  'java/lang/ThreadLocal::<init>()V': (rs) -> #NOP
  'java/util/concurrent/atomic/AtomicInteger::<clinit>()V': (rs) -> #NOP
  'java/util/concurrent/atomic/AtomicInteger::compareAndSet(II)Z': (rs) -> rs.push 1  # always true
  'sun/misc/Unsafe::getUnsafe()Lsun/misc/Unsafe;': ((rs) -> # avoid reflection
    rs.static_get({'class':'sun/misc/Unsafe','sig':{'name':'theUnsafe'}}))
  'java/util/concurrent/atomic/AtomicReferenceFieldUpdater::newUpdater(Ljava/lang/Class;Ljava/lang/Class;Ljava/lang/String;)Ljava/util/concurrent/atomic/AtomicReferenceFieldUpdater;': (rs) -> rs.push 0 # null
}
  
native_methods = {
  'java/lang/System::arraycopy(Ljava/lang/Object;ILjava/lang/Object;II)V': ((rs) -> 
    args = rs.curr_frame().locals
