Boost logo

Boost Users :

From: Larry (yg-boost-users_at_[hidden])
Date: 2003-08-29 12:22:02

 From boost-1.30.2 I built the list_parser.cpp example using MSVC++7.1.
In the CSV list I added ",,2" to the end of the line to be parsed. The
program ran but the neither of the added elements were included in the
output vector. Having used the tokenizer before I know it will
generally gobble up adjacent delimiters without any output. You can get
the empty token if you ask for the delimiters as well and then just
discard the delimiters (sort of). But I was surprised that the 2 didn't
make it to the output vector. I expected the empty list entry would not
make the output vector. I tried adding ~anychar_p to the rule but that
didn't help. If I change the input list to add ",\"\",2" I get "" and 2
in the output vector. Applications like spreadsheets do not put missing
column values for numeric columns as "" items generally. Maybe I am
missing something because it certainly isn't the behavior I would expect
(either from the parser or the tokenizer).

Boost-users list run by williamkempf at, kalb at, bjorn.karlsson at, gregod at, wekempf at