Ejemplo n.º 1
0
        private static bool ResolveNewLine(LexerContext context)
        {
            var stringSep = Environment.NewLine;

            if (stringSep.Length == 1 && stringSep.Equals(context.GetCurrentCharByString()))
            {
                return(true);
            }
            else if (stringSep.Length == 2 && !context.IsLast() && stringSep.Equals(context.GetCharPair()))
            {
                context.IncIndex();
                return(true);
            }
            return(false);
        }