celtic / rubyex

a Ruby VM/interpreter

This URL has Read+Write access

rubyex / vm / binding.h
100644 27 lines (19 sloc) 0.499 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#ifndef BINDING_H
#define BINDING_H
 
#include <map>
#include <string>
#include "renvironment.h"
#include "rvalue.h"
 
class Block;
 
class Binding
{
  public:
    Binding(RubyEnvironment &, RubyValue, RubyModule *);
    ~Binding();
 
    static std::string get_representation(linked_ptr<Binding> &, const std::vector<RubyValue> &);
 
    std::map<std::string, RubyValue> locals;
 
    RubyEnvironment &environment;
    RubyValue context;
    RubyModule *def_target; // where `def' points to.
};
 
#endif