code: public Object lookupSoyFunction(String name, int numArgs, SourceLocation location) {
      Object soyFunction = functions.get(name);
      if (soyFunction == null) {
        reportMissing(location, "function", name, functions.keySet());
        return ERROR_PLACEHOLDER_FUNCTION;
      }
      Set<Integer> validArgsSize;
      if (soyFunction instanceof SoyFunction) {
        validArgsSize = ((SoyFunction) soyFunction).getValidArgsSizes();
      } else {
        validArgsSize =
            getValidArgsSizes(
                soyFunction.getClass().getAnnotation(SoyFunctionSignature.class).value());
      }
      checkNumArgs("function", validArgsSize, numArgs, location);
      warnIfDeprecated(name, soyFunction, location);
      return soyFunction;
    }
docs: Returns a function with the given name and arity.
  
  <p>An error will be reported according to the current {@link Mode} and a placeholder function
  will be returned if it cannot be found.