Fix crash in lvalue_refs test.

Accessing the first element of a `std::vector` that is empty results in
a crash.
parent 4b64bbe1
......@@ -15,7 +15,7 @@ cdef void foo(vector[dpp] &bar, vector[vector[dp]] &baz) nogil:
def test_lvalue_ref_assignment():
cdef vector[dpp] bar
cdef vector[vector[dp]] baz
cdef vector[double] data
cdef vector[double] data = [0.0]
cdef dp bongle = &data[0]
bar.resize(1)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment