Example #1
0
        /// <summary>
        /// Validate a function call.
        /// </summary>
        /// <param name="e">
        ///            is the expression. </param>
        /// <returns> null. </returns>
        public virtual object visit(FunctionCall e)
        {
            QName name = e.name();

            if (!expandFunctionQName(name))
            {
                reportBadPrefix(name.prefix());
            }

            [email protected] qName = name.asQName();
            Function f = _sc.resolveFunction(qName, e.arity());

            if (f == null)
            {
                reportError(new StaticFunctNameError("Function does not exist: " + name.@string() + " arity: " + e.arity()));
            }
            e.set_function(f);
            _resolvedFunctions.Add(qName);

            visitExprs(e.GetEnumerator());
            return(null);
        }
Example #2
0
 /// <param name="e">
 ///            is the fucntion call. </param>
 /// <returns> e </returns>
 // XXX: how do we normalize ?
 public virtual object visit(FunctionCall e)
 {
     printExprs(e.GetEnumerator());
     return(e);
 }