Exemplo n.º 1
0
        public TConceptInfo QuickParse(string dsl, IConceptInfo contextParent)
        {
            Stack <IConceptInfo> context = new Stack <IConceptInfo>();

            context.Push(contextParent);

            tokenReader = GenericParserTest.TestTokenReader(dsl);
            return((TConceptInfo)Parse(tokenReader, context).Value);
        }
Exemplo n.º 2
0
        public TConceptInfo QuickParse(string dsl, Stack <IConceptInfo> context)
        {
            var contextNodes = new Stack <ConceptSyntaxNode>(context
                                                             .Select(ci => DslSyntax.CreateConceptSyntaxNode(ci)).Reverse());

            tokenReader = GenericParserTest.TestTokenReader(dsl);
            ConceptSyntaxNode node = GenericParser.Parse(tokenReader, contextNodes, out var warnings).Value;

            return((TConceptInfo)ConceptInfoHelper.ConvertNodeToConceptInfo(node));
        }
Exemplo n.º 3
0
 public TConceptInfo QuickParse(string dsl, Stack <IConceptInfo> context)
 {
     tokenReader = GenericParserTest.TestTokenReader(dsl);
     return((TConceptInfo)Parse(tokenReader, context).Value);
 }