jaxp/src/java.xml/share/classes/com/sun/org/apache/xpath/internal/compiler/FunctionTable.java
changeset 31497 4a6b2e733c0d
parent 31204 9afdbf18ad38
child 36520 cb52aa47ff0a
equal deleted inserted replaced
31302:f66c18528472 31497:4a6b2e733c0d
   376   {
   376   {
   377 
   377 
   378     int funcIndex;
   378     int funcIndex;
   379     Object funcIndexObj = getFunctionID(name);
   379     Object funcIndexObj = getFunctionID(name);
   380 
   380 
       
   381     if (func != null && !Function.class.isAssignableFrom(func)) {
       
   382         throw new ClassCastException(func.getName()
       
   383                   + " cannot be cast to "
       
   384                   + Function.class.getName());
       
   385     }
       
   386 
   381     if (null != funcIndexObj)
   387     if (null != funcIndexObj)
   382     {
   388     {
   383       funcIndex = ((Integer) funcIndexObj).intValue();
   389       funcIndex = ((Integer) funcIndexObj).intValue();
   384 
   390 
   385       if (funcIndex < NUM_BUILT_IN_FUNCS){
   391       if (funcIndex < NUM_BUILT_IN_FUNCS){