Method: Heist::Runtime#initialize
- Defined in:
- lib/heist/runtime/runtime.rb
#initialize(options = {}) ⇒ Runtime
A Runtime is initialized using a set of options. The available options include the following, all of which are false unless you override them yourself:
-
:continuations: set totrueto enablecall/cc -
:lazy: set totrueto enable lazy evaluation -
:unhygienic: set totrueto disable macro hygiene
46 47 48 49 50 51 52 53 54 55 56 57 |
# File 'lib/heist/runtime/runtime.rb', line 46 def initialize( = {}) @lazy = !![:lazy] @continuations = !![:continuations] @hygienic = ![:unhygienic] @top_level = Scope.new(self) @user_scope = Scope.new(@top_level) @stack = stackless? ? Stackless.new : Stack.new load_builtins() @start_time = Time.now.to_f end |