|
Boost Users : |
Subject: [Boost-users] Boost.Tokenizer / Sep - Compile-time errors ...
From: asif saeed (asif.lse2_at_[hidden])
Date: 2011-08-02 02:37:26
Hi,
Here is a piece of code that _only_ works when I provide it a hard-coded
constant ";":
typedef boost::char_separator<char_type_t> sep_type_t;
typedef boost::tokenizer<sep_type_t> tokenizer_t;
sep_(pa_->separator_.c_str()),
t_(messageString,sep_),
i_(t_.begin())
It wouldn't work with the separator passed in a variable
(pa_->separator.c_str()). Tokenizer wouldn't work even if I initialize a
const char* with a ";" and then pass that const char *variable to sep_
above. It gives me the following errors on if I pass separator in a
variable:
error C2780: 'bool boost::char_separator<Char>::operator
()(InputIterator &,InputIterator,Token &)' : expects 3 arguments - 1
provided
Any idea how I can pass it a separator in a variable?
Best, Asif
Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net