dbertoni    01/07/26 22:35:23

  Modified:    c/src/XSLT KeyTable.cpp
  Log:
  Removed an unnecessary cast and fixed a few code glitches.
  
  Revision  Changes    Path
  1.16      +6 -10     xml-xalan/c/src/XSLT/KeyTable.cpp
  
  Index: KeyTable.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/KeyTable.cpp,v
  retrieving revision 1.15
  retrieving revision 1.16
  diff -u -r1.15 -r1.16
  --- KeyTable.cpp      2001/07/08 18:48:39     1.15
  +++ KeyTable.cpp      2001/07/27 05:35:23     1.16
  @@ -113,11 +113,8 @@
   
                if(XalanNode::ELEMENT_NODE == pos->getNodeType())
                {
  -#if defined(XALAN_OLD_STYLE_CASTS)
  -                     attrs = ((const XalanElement*)pos)->getAttributes();
  -#else
  -                     attrs = static_cast<const 
XalanElement*>(pos)->getAttributes();
  -#endif
  +                     attrs = pos->getAttributes();
  +
                        nNodes = attrs->getLength();
           
                        if(0 == nNodes)
  @@ -171,7 +168,7 @@
                                } // if (kd.getInConstruction() == true)
                        } // end for(int i = 0; i < nDeclarations; ++i)
   
  -                     nodeIndex++;
  +                     ++nodeIndex;
   
                        if(0 != attrs)
                        {
  @@ -245,7 +242,7 @@
   
   
   
  -void
  +inline void
   KeyTable::addIfNotFound(
                        MutableNodeRefList&             theNodeList,
                        XalanNode*                              theNode)
  @@ -270,10 +267,9 @@
        // use attribute in xsl:key.
        assert(kd.getUse() != 0);
   
  -     const XObjectPtr        xuse =
  -                     kd.getUse()->execute(testNode, resolver, NodeRefList(), 
executionContext);
  +     const XObjectPtr        xuse(kd.getUse()->execute(testNode, resolver, 
NodeRefList(), executionContext));
   
  -     if(xuse->getType() != xuse->eTypeNodeSet)
  +     if(xuse->getType() != XObject::eTypeNodeSet)
        {
                addIfNotFound(
                        theKeys[kd.getName()][xuse->str()],
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to