Ejemplo n.º 1
0
        private Pair <Symbols.POINTER, Symbols.POINTER> ParsePointer()
        {
            Symbols.POINTER head = null, tail = null;
            while (scan.Peek().type == Token.Type.OP_STAR)
            {
                head = new Symbols.POINTER(scan.Read(), head);
                if (tail == null)
                {
                    tail = head;
                }
            }

            return(new Pair <Symbols.POINTER, Symbols.POINTER>(head, tail));
        }
Ejemplo n.º 2
0
        private Pair<Symbols.POINTER, Symbols.POINTER> ParsePointer()
        {
            Symbols.POINTER head = null, tail = null;
            while (scan.Peek().type == Token.Type.OP_STAR)
            {
                head = new Symbols.POINTER(scan.Read(), head);
                if (tail == null) { tail = head; }
            }

            return new Pair<Symbols.POINTER, Symbols.POINTER>(head, tail);
        }