dbertoni    2003/02/12 16:14:32

  Modified:    c/src/XSLT FunctionCurrent.cpp
  Log:
  Use new implementation of singleton node-set.
  
  Revision  Changes    Path
  1.14      +7 -15     xml-xalan/c/src/XSLT/FunctionCurrent.cpp
  
  Index: FunctionCurrent.cpp
  ===================================================================
  RCS file: /home/cvs/xml-xalan/c/src/XSLT/FunctionCurrent.cpp,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -r1.13 -r1.14
  --- FunctionCurrent.cpp       25 Nov 2002 18:11:52 -0000      1.13
  +++ FunctionCurrent.cpp       13 Feb 2003 00:14:32 -0000      1.14
  @@ -58,6 +58,10 @@
   
   
   
  +#include <XPath/XObjectFactory.hpp>
  +
  +
  +
   XALAN_CPP_NAMESPACE_BEGIN
   
   
  @@ -77,24 +81,12 @@
   XObjectPtr
   FunctionCurrent::execute(
                        XPathExecutionContext&  executionContext,
  -                     XalanNode*                              context,
  -                     const LocatorType*              locator) const
  +                     XalanNode*                              /* context */,
  +                     const LocatorType*              /* locator */) const
   {
        assert(executionContext.getCurrentNode() != 0);
   
  -     if (context == 0)
  -     {
  -             executionContext.error(
  -                     "The current() function is not allowed in patterns!",
  -                     context,
  -                     locator);
  -
  -             return XObjectPtr();
  -     }
  -     else
  -     {
  -             return 
executionContext.createNodeSet(*executionContext.getCurrentNode());
  -     }
  +     return 
executionContext.getXObjectFactory().createNodeSet(executionContext.getCurrentNode());
   }
   
   
  
  
  

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

Reply via email to