public virtual RuleFunction PopCurrentRule() { if (currentRule.Count > 0) return currentRule.Pop(); return null; }