Opened 7 years ago
Closed 5 years ago
#11616 closed Bugs (fixed)
Spirit unsigned to signed int comparison
Reported by: | Owned by: | Joel de Guzman | |
---|---|---|---|
Milestone: | To Be Determined | Component: | spirit |
Version: | Boost 1.59.0 | Severity: | Cosmetic |
Keywords: | Cc: |
Description
The following code generates warnings in with gcc (-Wall) and MSVC. The warnings reference signed to unsigned int comparison.
std::vector<float> values; std::string line = "111.2, 222.0, 333.3, 444.6, 555.5"; bool r = phrase_parse(line.begin(), line.end(), (float_ % ",") ,space, values);
The warnings can be silenced by changing the problem variables from size_t to int as shown in the attached patch although I'm not sure this is an ideal solution.
Attachments (1)
Change History (3)
by , 7 years ago
Attachment: | intpatch.patch added |
---|
comment:1 by , 5 years ago
comment:2 by , 5 years ago
Resolution: | → fixed |
---|---|
Status: | new → closed |
Note:
See TracTickets
for help on using tickets.
Was fixed in https://github.com/boostorg/spirit/pull/140 (Boost 1.60).