示例#1
0
        private bool TryPrefixOperator(Word w)
        {
            PrefixOperatorDef def = this.ctx.GetPrefixOperator(w.word);

            if (def == null)
            {
                return(false);
            }

            return(def.TryParse(w, this));
        }
示例#2
0
        private bool TryPrefixOperator(string word)
        {
            PrefixOperatorDef def = this.ctx.GetPrefixOperator(word);

            if (def == null)
            {
                return(false);
            }

            this.stk_parse.Push(new UnaryPrefixElement(def));
            return(true);
        }
示例#3
0
 public UnaryPrefixElement(PrefixOperatorDef def)
 {
     this.priority = def.prioR;
     this.op       = def.word;
 }