Am Fri, 21 Aug 2015 11:03:00 +0000 schrieb "Mike" <[email protected]>:
> On Friday, 21 August 2015 at 08:11:37 UTC, Kagamin wrote: > > On Friday, 21 August 2015 at 06:00:44 UTC, Mike wrote: > >> Disabling TypeInfo forces one to compromise on slicing, > >> postblit > > > > Why slicing and postblit would need typeinfo? > > See below for the source code. Some obvious, some not. > > * dynamic cast - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-83bcb64558f947e39f87d7435709dfe7R364 > * array literal - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-bed7d2226948b1e098749985d7a60633R2353 > * postblit - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-1f51c84492753de4c1863d02e24318bbR918 > * destructor - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-1f51c84492753de4c1863d02e24318bbR1039, > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-867588d7078efd0364c256152fb5a2e7R2053 > * new - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-5960d486a42197785b9eee4ba95c6b95R5091 > * AAs - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-5960d486a42197785b9eee4ba95c6b95R10710 > * slicing - > https://github.com/D-Programming-GDC/GDC/pull/100/files?diff=unified#diff-5960d486a42197785b9eee4ba95c6b95R11857 > > etc... > > Disabling TypeInfo requires quite a compromise on D's features. > I want TypeInfo, I just don't want dead code. > > Mike > > It's been some time since I looked at this so I don't remember exactly how severe these limitations are. However, it should be noted that not all 'array literals', ... need TypeInfo, only a subset of them does. Some are fixable others (dynamic downcast) probably not.
