Source Code Map¶
This document is a map of the source code, it describes what many of thedirectories/files contain.
ast.py¶
This contains each of the AST node classes. Each of these is responsible forencoding the structure of the program, and compiling itself to bytecode.
astcompiler.py¶
This contains utility classes for compiling ASTs to bytecode.
coerce.py¶
This contains logic for performing type coercion on Ruby objects. It containsimplementations for behaviors like, “this Ruby function takes an Integerargument”.
executioncontext.py¶
This contains logic specific to the current thread of execution in Ruby. Itmaintains things like the Ruby call stack.
frame.py¶
This contains Ruby frame objects, and associated logic for manipulating them.
gateway.py¶
This contains logic for exposing RPython functions in Ruby.
interpreter.py¶
This contains the bytecode interpreter itself.
lexer.py¶
This contains the hand written Ruby lexer.
main.py¶
This contains the command line entry-point, including things like argumentparsing logic.
module.py¶
This contains an API for exposing RPython classes in Ruby, it should be mergedwithgateway.py.
objspace.py¶
This contains theObjectSpace (unrelated to Ruby’sObjectSpace module),it is responsible for encoding the behaviors of Ruby, for example it containsmethods likefind_const,send, and methods for creating new Rubyobjects from RPython ones.
parser.py¶
This contains the parse rules and actions, built atoprply.
modules/¶
This contains built-in RubyModule objects. There is oneModule per file.
objects/¶
This contains built-in RubyClass objects. There is oneClass per file.