Bug 13081 – ICE with alias this and opSlice

Status
RESOLVED
Resolution
FIXED
Severity
regression
Priority
P1
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2014-07-08T22:55:00Z
Last change time
2014-08-22T08:04:16Z
Keywords
ice, industry, pull
Assigned to
nobody
Creator
briancschott

Comments

Comment #0 by briancschott — 2014-07-08T22:55:06Z
Code: ------- struct Cube(StorageT) { StorageT datastore; alias datastore this; auto seed() { this[] = node.data ? value : node.data; } } class SparseDataStore { auto opSlice() {} } void main() { Cube!SparseDataStore; } ------- Output with 2.065 test.d(7): Error: undefined identifier node test.d(7): Error: undefined identifier value test.d(7): Error: undefined identifier node test.d(12): Error: template instance test.Cube!(SparseDataStore) error instantiating Output with 2.066-devel-10f3bf1: dmd: statement.c:750: ErrorStatement::ErrorStatement(): Assertion `global.gaggedErrors || global.errors' failed. Aborted (core dumped)
Comment #1 by briancschott — 2014-07-08T23:22:44Z
#0 0x00007ffff7222f79 in __GI_raise (sig=sig@entry=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:56 #1 0x00007ffff7226388 in __GI_abort () at abort.c:89 #2 0x00007ffff721be36 in __assert_fail_base (fmt=0x7ffff736d718 "%s%s%s:%u: %s%sAssertion `%s' failed.\n%n", assertion=assertion@entry=0x5b2530 "global.gaggedErrors || global.errors", file=file@entry=0x5b1d29 "statement.c", line=line@entr y=750, function=function@entry=0x5b3340 <ErrorStatement::ErrorStatement()::__PRETTY_FUNCTION__> "ErrorStatement::ErrorStatement()") at assert.c:92 #3 0x00007ffff721bee2 in __GI___assert_fail (assertion=0x5b2530 "global.gaggedErrors || global.errors", file=0x5b1d29 "statement.c", line=750, function=0x5b3340 <ErrorStatement::ErrorStatement()::__PRETTY_FUNCTION__> "ErrorStatement::Erro rStatement()") at assert.c:101 #4 0x000000000043e33d in ErrorStatement::ErrorStatement (this=<optimized out>) at statement.c:750 #5 0x000000000043e3d5 in ExpStatement::semantic (this=<optimized out>, sc=0x960950) at statement.c:833 #6 0x0000000000442b9a in CompoundStatement::semantic (this=0x95e970, sc=0x960950) at statement.c:1035 #7 0x00000000004ece32 in FuncDeclaration::semantic3 (this=<optimized out>, sc=0x960230) at func.c:1573 #8 0x000000000044af98 in AggregateDeclaration::semantic3 (this=0x95df40, sc=0x95ff20) at struct.c:228 #9 0x000000000044f2e4 in TemplateInstance::semantic3 (this=0x893f20, sc=0x95ff20) at template.c:7639 #10 0x0000000000457823 in TemplateInstance::trySemantic3 (this=this@entry=0x893f20, sc2=sc2@entry=0x95ea20) at template.c:5979 #11 0x000000000045cecc in TemplateInstance::semantic (this=0x893f20, sc=<optimized out>, fargs=<optimized out>) at template.c:6403 #12 0x00000000004d19d4 in ScopeExp::semantic (this=0x894110, sc=0x95c080) at expression.c:4589 #13 0x000000000043e35b in ExpStatement::semantic (this=0x894150, sc=0x95c080) at statement.c:826 #14 0x0000000000442b9a in CompoundStatement::semantic (this=0x894170, sc=0x95c080) at statement.c:1035 #15 0x00000000004ece32 in FuncDeclaration::semantic3 (this=<optimized out>, sc=0x95bb90) at func.c:1573 #16 0x0000000000407df0 in Module::semantic3 (this=this@entry=0x892380) at module.c:775 #17 0x000000000040566c in tryMain (argc=5, argv=0x89e200) at mars.c:1659 #18 0x00007ffff720dec5 in __libc_start_main (main=0x402610 <main(int, char const**)>, argc=2, argv=0x7fffffffdf48, init=<optimized out>, fini=<optimized out>, rtld_fini=<optimized out>, stack_end=0x7fffffffdf38) at libc-start.c:287 #19 0x0000000000402b45 in _start ()
Comment #2 by k.hara.pg — 2014-07-09T02:28:29Z
Comment #3 by github-bugzilla — 2014-07-09T03:34:08Z
Commits pushed to master at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/9c13bc30ef5d93fbc3d36b08356106a366b88a16 fix Issue 13081 - ICE with alias this and opSlice https://github.com/D-Programming-Language/dmd/commit/e85556a7f645bd91b1bc4883493a5835e04ce175 Merge pull request #3732 from 9rnsr/fix13081 [REG2.066a] Issue 13081 - ICE with alias this and opSlice
Comment #4 by github-bugzilla — 2014-07-11T14:46:53Z
Commit pushed to 2.066 at https://github.com/D-Programming-Language/dmd https://github.com/D-Programming-Language/dmd/commit/e18332655fbe96ccd640d4f005e30b936d6f884b Merge pull request #3732 from 9rnsr/fix13081 [REG2.066a] Issue 13081 - ICE with alias this and opSlice
Comment #5 by github-bugzilla — 2014-08-22T08:04:16Z