--- parser3/src/include/pa_pool.h 2001/03/29 08:28:03 1.46 +++ parser3/src/include/pa_pool.h 2001/04/04 06:16:19 1.48 @@ -5,7 +5,7 @@ Author: Alexander Petrosyan (http://design.ru/paf) - $Id: pa_pool.h,v 1.46 2001/03/29 08:28:03 paf Exp $ + $Id: pa_pool.h,v 1.48 2001/04/04 06:16:19 paf Exp $ */ #ifndef PA_POOL_H @@ -15,7 +15,6 @@ class Exception; class Temp_exception; -class Request; /** Pool mechanizm allows users not to free up allocated memory, @@ -26,17 +25,18 @@ class Request; @see Pooled */ + class Pool { friend Temp_exception; public: - Pool(void *astorage) : fstorage(astorage), fcontext(0), frequest(0), fexception(0) {} + Pool(void *astorage) : fstorage(astorage), fcontext(0), ftag(0), fexception(0) {} void set_context(void *acontext) { fcontext=acontext; } void *context() { return fcontext; } - void set_request(Request *arequest) { frequest=arequest; } - Request *request() { return frequest; } + void set_tag(void *atag) { ftag=atag; } + void *tag() { return ftag; } /// current exception object of the pool Exception& exception() const { return *fexception; } @@ -54,7 +54,7 @@ private: void *fstorage; void *fcontext; - Request *frequest; + void *ftag; private: // implementation defined @@ -191,8 +191,6 @@ public: #define PTHROW XTHROW(pool.exception()) #define PCATCH(e) XCATCH(e) #define PEND_CATCH XEND_CATCH - -#define RTHROW XTHROW(r.pool().exception()) //@} #endif