792. piecewise_constant_distribution is undefined for a range with just one endpoint

Section: 29.5.9.6.2 [rand.dist.samp.pconst] Status: CD1 Submitter: P.J. Plauger Opened: 2008-02-09 Last modified: 2016-01-28

Priority: Not Prioritized

View all other issues in [rand.dist.samp.pconst].

View all issues with CD1 status.

Discussion:

piecewise_constant_distribution is undefined for a range with just one endpoint. (Probably should be the same as an empty range.)

Proposed resolution:

Change 29.5.9.6.2 [rand.dist.samp.pconst] paragraph 3b:

b) If firstB == lastB or the sequence w has the length zero,