Bug 3808 – Assertion Failure : Assertion failure: 'classinfo->structsize == CLASSINFO_SIZE' on line 870 in file 'toobj.c'

Status
RESOLVED
Resolution
FIXED
Severity
blocker
Priority
P2
Component
dmd
Product
D
Version
D2
Platform
x86
OS
Windows
Creation time
2010-02-16T14:23:00Z
Last change time
2015-06-09T05:15:19Z
Keywords
ice-on-invalid-code, patch
Assigned to
nobody
Creator
petitv.isat

Attachments

IDFilenameSummaryContent-TypeSize
568D-Assertion_Failure.zipsc.ini, makefile, binding, screenapplication/x-zip-compressed747485

Comments

Comment #0 by petitv.isat — 2010-02-16T14:23:36Z
Created attachment 568 sc.ini, makefile, binding, screen Well, I found this bug when I was trying to make the win32lib from the binding available on Dsource.org. I'll try to explain the environment with lot of details : 1. DMD Compiler : Version 1.033, 1.056 ; 2.040, dmd2beta have been "tested". Each one returned the bug. So, the version of the compiler don't play a role to have this bug. 2. Libraries : - Standard Library : tango 0.98 and tango 0.99.9 kai have been tried too. Same result. - Others : tried with and without these ones : tangobos (latest), DFL (latest), INI (from dprogramming.com). Nothing changed the result. 3. Binding : - Win32 from DSource - the latest one from trunk version (trunk-r337) 4. Attachement : - The makefile for the binding (and the binding itself) - A screen from my dmd\lib directory - sc.ini file I'm using (there's lot of comments cause of tests I made for this bug or other things ...)
Comment #1 by petitv.isat — 2010-02-16T14:25:18Z
Well, I found this bug when I was trying to make the win32lib from the binding available on Dsource.org. I'll try to explain the environment with lot of details : 1. DMD Compiler : Version 1.033, 1.056 ; 2.040, dmd2beta have been "tested". Each one returned the bug. So, the version of the compiler don't play a role to have this bug. 2. Libraries : - Standard Library : tango 0.98 and tango 0.99.9 kai have been tried too. Same result. - Others : tried with and without these ones : tangobos (latest), DFL (latest), INI (from dprogramming.com). Nothing changed the result. 3. Binding : - Win32 from DSource - the latest one from trunk version (trunk-r337) 4. Attachement : - The makefile for the binding (and the binding itself) - A screen from my dmd\lib directory - sc.ini file I'm using (there's lot of comments cause of tests I made for this bug or other things ...)
Comment #2 by clugdbug — 2010-03-11T08:18:50Z
This is caused by an incorrectly installed DMD (wrong phobos.lib). However, the compiler should say that, instead of failing with an assert).
Comment #3 by clugdbug — 2010-03-15T14:02:16Z
The error message should be improved. I suggest something like this: toobj, line 995: if (vtblInterfaces->dim) { - if (classinfo) - assert(classinfo->structsize == CLASSINFO_SIZE); + if (classinfo && classinfo->structsize != CLASSINFO_SIZE) + error("Incorrect installation. D compiler and phobos' typeinfo are mismatched"); offset = CLASSINFO_SIZE; dtxoff(&dt, csym, offset, TYnptr); // (*)
Comment #4 by bugzilla — 2010-03-28T14:13:34Z
changeset 425
Comment #5 by clugdbug — 2010-04-09T13:41:54Z
Fixed DMD1.058 and 2.043.