Sha256: 7c857fc4815cca3b919c34c5c6b4d091110b92898c66d66fb5bfe3e1e813caba

Contents?: true

Size: 488 Bytes

Versions: 2

Compression:

Stored size: 488 Bytes

Contents

# These are all the functions needed for Cuby
# Pretty cool eh?
# Jon Vlachoyiannis (jon@emotionull.com)
# (16/10/2009)
    
def include(filename)
  require filename
end

def main(&block)
  instance_eval(&block)
end

def method_missing(meth, *args, &block)
  self.class.send(:define_method, meth, *args, &block)
end

def preformat_data(data)
  data.gsub(/^\s*\/\//,'#')
end

#FIXME Interactive mode does not work with loop defined
# def loop(start, cond, action, &block)
#   return
# end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cuby-0.1.4 lib/cuby/vm.rb
cuby-0.1.3 lib/cuby/vm.rb