Ticket #6368: clear_queue.patch

File clear_queue.patch, 7.1 KB (added by anonymous, 11 years ago)
  • boost/spirit/home/support/iterators/detail/combine_policies.hpp

     
    4141            Input::destroy(mp);
    4242            Storage::destroy(mp);
    4343        }
     44
    4445        void swap(multi_pass_unique& x)
    4546        {
    4647            this->Ownership::swap(x);
     
    4849            this->Input::swap(x);
    4950            this->Storage::swap(x);
    5051        }
     52
     53        template <typename MultiPass>
     54        inline static void clear_queue(MultiPass& mp)
     55        {
     56            Checking::clear_queue(mp);
     57            Storage::clear_queue(mp);
     58        }
    5159    };
    5260#else
    5361    ///////////////////////////////////////////////////////////////////////////
     
    7886            Input::destroy(mp);
    7987            Storage::destroy(mp);
    8088        }
     89
    8190        void swap(multi_pass_unique& x)
    8291        {
    8392            this->Ownership::swap(x);
     
    8594            this->Input::swap(x);
    8695            this->Storage::swap(x);
    8796        }
     97
     98        template <typename MultiPass>
     99        inline static void clear_queue(MultiPass& mp)
     100        {
     101            Checking::clear_queue(mp);
     102            Storage::clear_queue(mp);
     103        }
    88104    };
    89105   
    90106    ///////////////////////////////////////////////////////////////////////////
     
    105121            Input::destroy(mp);
    106122            Storage::destroy(mp);
    107123        }
     124
    108125        void swap(multi_pass_unique& x)
    109126        {
    110127            this->Ownership::swap(x);
     
    112129            this->Storage::swap(x);
    113130        }
    114131
     132        template <typename MultiPass>
     133        inline static void clear_queue(MultiPass& mp)
     134        {
     135            Checking::clear_queue(mp);
     136            Storage::clear_queue(mp);
     137        }
     138
    115139        // implement input policy functions by forwarding to the Input type
    116140        template <typename MultiPass>
    117141        inline static void advance_input(MultiPass& mp)
     
    148172            Input::destroy(mp);
    149173            Storage::destroy(mp);
    150174        }
     175
    151176        void swap(multi_pass_unique& x)
    152177        {
    153178            this->Ownership::swap(x);
     
    155180            this->Storage::swap(x);
    156181        }
    157182
     183        template <typename MultiPass>
     184        inline static void clear_queue(MultiPass& mp)
     185        {
     186            Checking::clear_queue(mp);
     187            Storage::clear_queue(mp);
     188        }
     189
    158190        // checking policy functions are forwarded to the Checking type
    159191        template <typename MultiPass>
    160192        inline static void docheck(MultiPass const& mp)
    161193            { Checking::docheck(mp); }
    162 
    163         template <typename MultiPass>
    164         inline static void clear_queue(MultiPass& mp)
    165             { Checking::clear_queue(mp); }
    166194    };
    167195
    168196    ///////////////////////////////////////////////////////////////////////////
     
    182210            Input::destroy(mp);
    183211            Storage::destroy(mp);
    184212        }
     213
    185214        void swap(multi_pass_unique& x)
    186215        {
    187216            this->Ownership::swap(x);
    188217            this->Storage::swap(x);
    189218        }
    190219
     220        template <typename MultiPass>
     221        inline static void clear_queue(MultiPass& mp)
     222        {
     223            Checking::clear_queue(mp);
     224            Storage::clear_queue(mp);
     225        }
     226
    191227        // implement input policy functions by forwarding to the Input type
    192228        template <typename MultiPass>
    193229        inline static void advance_input(MultiPass& mp)
     
    209245        template <typename MultiPass>
    210246        inline static void docheck(MultiPass const& mp)
    211247            { Checking::docheck(mp); }
    212 
    213         template <typename MultiPass>
    214         inline static void clear_queue(MultiPass& mp)
    215             { Checking::clear_queue(mp); }
    216248    };
    217249
    218250    ///////////////////////////////////////////////////////////////////////////
     
    233265            Input::destroy(mp);
    234266            Storage::destroy(mp);
    235267        }
     268
    236269        void swap(multi_pass_unique& x)
    237270        {
    238271            this->Checking::swap(x);
     
    240273            this->Storage::swap(x);
    241274        }
    242275
     276        template <typename MultiPass>
     277        inline static void clear_queue(MultiPass& mp)
     278        {
     279            Checking::clear_queue(mp);
     280            Storage::clear_queue(mp);
     281        }
     282
    243283        // ownership policy functions are forwarded to the Ownership type
    244284        template <typename MultiPass>
    245285        inline static void clone(MultiPass& mp)
     
    271311            Input::destroy(mp);
    272312            Storage::destroy(mp);
    273313        }
     314
    274315        void swap(multi_pass_unique& x)
    275316        {
    276317            this->Checking::swap(x);
    277318            this->Storage::swap(x);
    278319        }
    279320
     321        template <typename MultiPass>
     322        inline static void clear_queue(MultiPass& mp)
     323        {
     324            Checking::clear_queue(mp);
     325            Storage::clear_queue(mp);
     326        }
     327
    280328        // implement input policy functions by forwarding to the Input type
    281329        template <typename MultiPass>
    282330        inline static void advance_input(MultiPass& mp)
     
    325373            Input::destroy(mp);
    326374            Storage::destroy(mp);
    327375        }
     376
    328377        void swap(multi_pass_unique& x)
    329378        {
    330379            this->Input::swap(x);
    331380            this->Storage::swap(x);
    332381        }
    333382
     383        template <typename MultiPass>
     384        inline static void clear_queue(MultiPass& mp)
     385        {
     386            Checking::clear_queue(mp);
     387            Storage::clear_queue(mp);
     388        }
     389
    334390        // checking policy functions are forwarded to the Checking type
    335391        template <typename MultiPass>
    336392        inline static void docheck(MultiPass const& mp)
    337393            { Checking::docheck(mp); }
    338394
    339         template <typename MultiPass>
    340         inline static void clear_queue(MultiPass& mp)
    341             { Checking::clear_queue(mp); }
    342 
    343395        // ownership policy functions are forwarded to the Ownership type
    344396        template <typename MultiPass>
    345397        inline static void clone(MultiPass& mp)
     
    370422            Input::destroy(mp);
    371423            Storage::destroy(mp);
    372424        }
     425
    373426        void swap(multi_pass_unique& x)
    374427        {
    375428            this->Storage::swap(x);
    376429        }
    377430
     431        template <typename MultiPass>
     432        inline static void clear_queue(MultiPass& mp)
     433        {
     434            Checking::clear_queue(mp);
     435            Storage::clear_queue(mp);
     436        }
     437
    378438        // implement input policy functions by forwarding to the Input type
    379439        template <typename MultiPass>
    380440        inline static void advance_input(MultiPass& mp)
     
    397457        inline static void docheck(MultiPass const& mp)
    398458            { Checking::docheck(mp); }
    399459
    400         template <typename MultiPass>
    401         inline static void clear_queue(MultiPass& mp)
    402             { Checking::clear_queue(mp); }
    403 
    404460        // ownership policy functions are forwarded to the Ownership type
    405461        template <typename MultiPass>
    406462        inline static void clone(MultiPass& mp)