llvm-project icon indicating copy to clipboard operation
llvm-project copied to clipboard

clang crashes with arrays of std::complex

Open KarstenH opened this issue 9 years ago • 2 comments

Bugzilla Link 32822
Resolution FIXED
Resolved on Dec 08, 2017 06:54
Version trunk
OS Windows XP
Attachments Error message with Visual Studio 2017
CC @DougGregor

Extended Description

#include

// clang crashes here with any array size > 1 std::complex v[2];

// I suppose the reason is a constexpr constructor with the parameter type being const &. Please see the following explanation and the attachment

struct A { constexpr A(const int & = 0) {} }; struct B // = A without & { constexpr B(const int /&/ = 0) {} }; struct C // = A without constexpr { /constexpr/ C(const int & = 0) {} };

A a1[1]; // OK A a2[2]; // clang crashes B b[2]; // OK C c[2]; // OK

KarstenH avatar Apr 27 '17 05:04 KarstenH

This has been fixed. See Bug 34858.

KarstenH avatar Dec 08 '17 14:12 KarstenH

After almost 5 months I would like to know whether or not this issue is going to be fixed. Does anybody care at all?

KarstenH avatar Sep 15 '17 04:09 KarstenH