Bug 12677 – Assertion failure: 'isCtfeValueValid(newval)' on line 6579 in file 'interpret.c'

Status
RESOLVED
Resolution
FIXED
Severity
normal
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-04-28T22:22:00Z
Last change time
2014-06-08T23:26:24Z
Keywords
CTFE, ice, pull
Assigned to
nobody
Creator
puremagic

Comments

Comment #0 by puremagic — 2014-04-28T22:22:46Z
http://dpaste.dzfl.pl/4e6442766087 code: import std.typetuple; import std.stdio; struct A { auto f = new FOO(); } final class FOO { TypeTuple!(Object, Object) _test; this() { foreach(t; _test) { } } } void main() { A a; "success".writeln; } result: /d856/f127.d(12): Error: CTFE internal error: illegal value FOO(null, null).__test_field_0 dmd: interpret.c:6579: void VarDeclaration::setValue(Expression*): Assertion `isCtfeValueValid(newval)' failed.
Comment #1 by k.hara.pg — 2014-06-08T11:51:26Z
Comment #2 by github-bugzilla — 2014-06-08T23:26:23Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/cf05dc3440fff978954854974d1f3272458861a8 fix Issue 12677 - Assertion failure: 'isCtfeValueValid(newval)' on line 6579 in file 'interpret.c' https://github.com/D-Programming-Language/dmd/commit/43c624ed76314678aa5fa6cafb82d7780b6c16db Merge pull request #3649 from 9rnsr/fix12677 Issue 12677 - Assertion failure: 'isCtfeValueValid(newval)' on line 6579 in file 'interpret.c'