示例#1
0
        public void Parse()
        {
            _rootTree = _parser.root();

            ParseTreeWalker walker = new ParseTreeWalker();

            walker.Walk(new ParseCpuPass(this), _rootTree);

            if (Errors.Count > 0)
            {
                throw new CompilerErrorException();
            }

            resolveLabels();
            verifyBranchLength();

            if (Errors.Count > 0)
            {
                throw new CompilerErrorException();
            }
        }
示例#2
0
        public void Parse()
        {
            _rootTree = _parser.root();

            ParseTreeWalker walker = new ParseTreeWalker();
            walker.Walk(new ParseCpuPass(this), _rootTree);

            if (Errors.Count > 0)
            {
                throw new CompilerErrorException();
            }

            resolveLabels();
            verifyBranchLength();

            if (Errors.Count > 0)
            {
                throw new CompilerErrorException();
            }
        }