Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
4.1.2, 4.1.3
-
None
-
all
Description
The program below aborts at runtime with the latest trunk:
$ cat t.cpp && nice gmake t && ./t
#include <cassert>
#include <cstddef>
#include <valarray>
int main ()
{
const int a[] =
;
const std::valarray<int> v (a, sizeof a / sizeof *a);
const std::size_t start = 5;
std::valarray<std::size_t> length (1, 1);
std::valarray<std::size_t> stride (1, 1);
const std::gslice gsl (start, length, stride);
const std::valarray<int> vsl = v [gsl];
assert (a [start] == vsl [0]);
}
aCC -c -I/nfs/devco/sebor/dev/stdlib/include/ansi -I/usr/include -D_RWSTDDEBUG -mt -D_RWSTD_USE_CONFIG -I/nfs/devco/sebor/dev/stdlib/include -I/build/sebor/aCC-3.70-15S/include -I/nfs/devco/sebor/dev/stdlib/examples/include -Aa +nostl -g +d +DD64 +w +W392 +W655 +W684 +W818 +W819 +W849 t.cpp
aCC t.o -o t -Aa +nostl -Wl,+s -Wl,+vnocompatwarnings -mt +DD64 -L/build/sebor/aCC-3.70-15S/lib -lstd15S -lm
Assertion failed: a [start] == vsl [0], file t.cpp, line 19
ABORT instruction (core dumped)