digitalmars.D.bugs - [Issue 19224] New: core.simd __vector.array "__r2.length cannot be
- d-bugmail puremagic.com (37/37) Sep 05 2018 https://issues.dlang.org/show_bug.cgi?id=19224
https://issues.dlang.org/show_bug.cgi?id=19224 Issue ID: 19224 Summary: core.simd __vector.array "__r2.length cannot be evaluated at compile time" Product: D Version: D2 Hardware: All OS: All Status: NEW Severity: normal Priority: P1 Component: dmd Assignee: nobody puremagic.com Reporter: n8sh.secondary hotmail.com Example non-compiling code: https://run.dlang.io/is/zJJlZl --- float sum(const float[4] val) { float sum = 0; foreach (x; val) sum += x; return sum; } void main() { import core.simd : float4; enum x = sum(float4.init.array); } --- Error message: """ Error: __r2.length cannot be evaluated at compile time" onlineapp.d(11): called from here: sum(cast(__vector(float[4]))[nanF, nanF, nanF, nanF]) """ --
Sep 05 2018