|
Boost : |
From: Ovanes Markarian (om_boost_at_[hidden])
Date: 2006-08-10 10:39:58
An assertion bug with VC 8.0 is partially correct at least in the version I found in CVS.
options_description.cpp revision=1.16.2.1
This calculation does not assume the indent in the line used. The line_length added produces
longer line sequence as would fit in the line, so a line wrap occurs. The output looks somehow
ugly:
-v [--version] test line dkakal alalalala a sdk
dkdkdkd
instead of:
-v [--version] test line dkakal alalalala a sdk
dkdkdkd
Current calc:
LineNo.
393 // Take care to never increment the iterator past 394
// the end, since MSVC 8.0 (brokenly), assumes that 395 // doing that, even
if no access happens, is a bug. 396 unsigned remaining =
distance(line_begin, par_end); 397 string::const_iterator line_end =
line_begin + 398 ((remaining < line_length) ? remaining : line_length);
My proposal would be adding before the while loop (line 377):
size_t offset = line_length - indent;
LineNo.
393 // Take care to never increment the iterator past 394
// the end, since MSVC 8.0 (brokenly), assumes that 395 // doing that, even
if no access happens, is a bug. 396 unsigned remaining =
distance(line_begin, par_end); 397 string::const_iterator line_end =
line_begin + 398 ((remaining < offset) ? remaining : offset);
With Kind Regards,
Ovanes Markarian
With Kind Regards,
Ovanes
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk