Пример #1
0
        void CompileClassDeclaration(ClassDeclaration classDeclaration)
        {
            var type = typeDefinitionByName[classDeclaration.Name];

            foreach (var classMethod in classDeclaration.Members.OfType <ClassMethod>())
            {
                var method = classMethodDefinitionByNode[classMethod];
                MethodBodyCompiler.Compile(sourceFile, allTypes, method, classMethod.Body.Statements);
            }
        }
Пример #2
0
 void CompileMainMethod()
 {
     MethodBodyCompiler.Compile(sourceFile, allTypes, MainMethod, programNode.Statements);
 }
Пример #3
0
        void CompileFunctionDeclaration(FunctionDeclaration functionDeclaration)
        {
            var method = functionMethodDefinitionByNode[functionDeclaration];

            MethodBodyCompiler.Compile(sourceFile, allTypes, method, functionDeclaration.Body.Statements);
        }