61 operator std::string ()
const {
88 template<
class CharSeq>
99 template<
class CharSeq>
114 template<
class CharSeq>
121 template<
class CharSeq>
131 template<
class CharSeq>
147 size_t mark = size_t(chew);
149 if (mark !=
size_t(chew)) {
156 size_t len = _canonical.length();
157 if (_canonical[len - 1] ==
' ') {
158 _canonical.resize(len - 1);
163 template<
class CharSeq>
166 int paren_balance = 0;
175 if (--paren_balance < 0) {
182 if (paren_balance <= 0) {
188 if (!isspace(*chew)) {
192 if (_canonical.size()) {
193 auto last = _canonical.
back();
194 if (!isspace(last) && (last ==
'#' || !ispunct(last))) {
template struct traits::is_random_access_char_sequence<T> exports a static const boolean member value...
void back(size_t n)
Retreat the scanning position an amount.
void canonicalize(CharSeq &seq)
Canonicalize from a CharSeq>
A tag class for parameterizing template class canonical<What>
chew_mode::c_comment const c_comment
An exemplar chew_mode::c_comment
canonical(chewer< CharSeq > &chew)
Explicitly construct from a chewer<CharSeq>
chew_mode::continuation const continuation
An exemplar chew_mode::continuation
chew_mode::greyspace const greyspace
An exemplar chew_mode::greyspace
`template struct chewer<CharSeq> is a cursor-like type that is associated with a character-sequence t...
template class canonical<What> encapsulates the canonical representation of values of type What...
void canonicalize(chewer< CharSeq > &chew)
Canonicalize from a chewer<CharSeq>
A base for classes representing canonical forms of various types.
struct symbol encapsulates a preprocessor symbol's state
std::string _canonical
String storing the canonical representation of a value.
bool cxx() const
Canonicalizing C/C++ source?
canonical(CharSeq &seq)
Explicitly construct from a character-sequence.