written a code that parses through a file reading it line by line and splitting it into tokens by white space. But I want a pair of single quotes to be one token, not how many words are in it,
For example I want something like
Done a'ccept command' Done
to be three tokens not four the three bieng
first Done second a'ccept command' third bieng Done.
So far I have
void file_parser::check_quote(tokens) {
boolean has_quote;
for (int i = 0; i <= tokens.size(); i++) {
String temp = tokens.c_str();
for (int i = 0; i <= tokens.size(); i++) {
if (tmp[i] == '\'') {
has_quote = true;
int FirstQuote = i;
}
if (has_quote && i != FirstQuote && tmp[i] == '\'') {
int SecondQuote = i;
for (int k = FirstQuote; k <= SecondQuote; i++) {
}
}
}
}