public class AmbiguousSymbolException extends SymbolException
For a function lookup, this will only happen if more than one function
can possibly match a set of runtime arguments, and one or more of those
arguments is null
, such that a type match for that argument
is ambiguous between alternative functions. This can occur between
overloaded functions in the same namespace, or between unqualified
functions when a cross-namespace lookup occurs.
For a variable lookup, this will only happen if the variable symbol is unqualified in a user expression, and a cross-namespace lookup turns up more than one match for that variable name.
This is an unchecked exception for performance reasons, so that the caller is not required to set up an expensive try-catch block in all cases. This is appropriate because this exception can easily be avoided by registering only non-overloaded functions, or implementing client code such that an ambiguous match cannot occur.
Constructor and Description |
---|
AmbiguousSymbolException(java.lang.String message)
Constructor which accepts an error message.
|