Nitro.CompilationServices Class Reference

Detailed Description

Provides some global methods for compiling operations into executable instructions.

Static Public Member Functions

static void CompileOperators (OperationFragment fragment, CompiledMethod parentBlock)
 Compiles an operation fragment into an executable operation. The fragment may contain multiple operators and some may even be the same so the furthest right takes priority; 1+2+3 becomes 1+(2+3). The compiled fragments are placed back into the same operation fragment. When it's complete, the operation will only contain one compiled fragment. More...
 
static bool CompileOperations (CodeFragment fragment, CompiledMethod block)
 Compiles all operations in a given fragment into executable IL. More...
 
static CompiledFragment[] CompileParameters (CodeFragment brackets, CompiledMethod parentBlock)
 Compiles a set of parameters into an array of compiled fragments. More...
 

Member Function Documentation

static bool Nitro.CompilationServices.CompileOperations ( CodeFragment  fragment,
CompiledMethod  block 
)
inlinestatic

Compiles all operations in a given fragment into executable IL.

Parameters
fragmentThe parent fragment. Most likely represents a pair of brackets.
blockThe method that the operations represent.
Returns
True if the block returns something.
static void Nitro.CompilationServices.CompileOperators ( OperationFragment  fragment,
CompiledMethod  parentBlock 
)
inlinestatic

Compiles an operation fragment into an executable operation. The fragment may contain multiple operators and some may even be the same so the furthest right takes priority; 1+2+3 becomes 1+(2+3). The compiled fragments are placed back into the same operation fragment. When it's complete, the operation will only contain one compiled fragment.

Parameters
fragmentThe operation fragment to compile.
parentBlockThe method the operations are compiling into.
static CompiledFragment [] Nitro.CompilationServices.CompileParameters ( CodeFragment  brackets,
CompiledMethod  parentBlock 
)
inlinestatic

Compiles a set of parameters into an array of compiled fragments.

Parameters
bracketsThe parent block which contains each parameter as a child.
parentBlockThe method the parameters are for.
Returns
A set of compiled fragments.