digitalmars.D.learn - Assertion failure: '!vthis->csym' on line 703 in file 'glue.c'
- nrgyzer (10/10) Mar 26 2011 Hey guys,
- bearophile (4/5) Mar 26 2011 I suggest to copy your code, and then keep removing lines from your copy...
- David Nadlinger (11/12) Mar 26 2011 You don't necessarily need fancy tools to do that – as I recently
- nrgyzer (31/43) Mar 27 2011 your copy, making sure it keep showing the same compiler error. In
- bearophile (4/6) Mar 27 2011 You may have to start over then. I suggest to duplicate the whole code, ...
- nrgyzer (17/23) Mar 27 2011 code, and then start on the copied version removing modules and lines
- Don (4/12) Mar 28 2011 It's still the same bug. The source code for the backend is the same for...
Hey guys, I got "Assertion failure: '!vthis->csym' on line 703 in file 'glue.c'" after I add "LinkList!(uint) myList;" to my source file. I figured out that the same bug was already reported on http://lists.puremagic.com/ pipermail/digitalmars-d-bugs/2010-October/019237.html Ticket 4129 describes a bug in glue.c but for DMD 1.x and I'm using DMD 2.052. I can't also reproduce the error in other projects - it seems that it only exists in this project. In this case I think it makes no sense to post thousand lines of code. Thus I hope anyone know what can be wrong => thanks!
Mar 26 2011
nrgyzer:In this case I think it makes no sense to post thousand lines of code.I suggest to copy your code, and then keep removing lines from your copy, making sure it keep showing the same compiler error. In some time you will probably be able to produce a small program, fit for this newsgroup or even for Bugzilla. (There are tools to do this reduction automatically in Python, I think). Bye, bearophile
Mar 26 2011
On 3/26/11 11:08 PM, bearophile wrote:I suggest to copy your code, and then keep removing lines from your copy, making sure it keep showing the same compiler error. In some time you will probably be able to produce a small program, fit for this newsgroup or even for Bugzilla. (There are tools to do this reduction automatically in Python, I think).You don't necessarily need fancy tools to do that – as I recently pointed out in another thread, the Tigris »delta« tool worked fine for me on several occasions (http://delta.tigris.org/). Just write a simple shell script looking for the error message in the compiler output, and delta will try to automatically reduce the file for you. There is some room for improvement though when you have an actual lexer/parser available for heuristically determining what pieces of code to delete – this might be a nice demonstration project for a D parsing library. David
Mar 26 2011
== Auszug aus David Nadlinger (see klickverbot.at)'s ArtikelOn 3/26/11 11:08 PM, bearophile wrote:your copy, making sure it keep showing the same compiler error. In some time you will probably be able to produce a small program, fit for this newsgroup or even for Bugzilla. (There are tools to do this reduction automatically in Python, I think).I suggest to copy your code, and then keep removing lines fromYou don't necessarily need fancy tools to do that – as I recently pointed out in another thread, the Tigris »delta« tool workedfine forme on several occasions (http://delta.tigris.org/). Just write asimpleshell script looking for the error message in the compiler output,anddelta will try to automatically reduce the file for you. There is some room for improvement though when you have an actual lexer/parser available for heuristically determining what pieces ofcodeto delete – this might be a nice demonstration project for a Dparsinglibrary. DavidI figured out what produces the error - "import dcollections.LinkList;" (declared as private) in one source file. But I'm still unable to reproduce that error in a sample-application. What I currently can say, that I have two source files like: module firstModule; private { import dcollections.LinkList; LinkList!(uint) myPrivateList; } static this() { myPrivateList = new LinkList!(uint); } module secondModule; import firstModule; import dcollections.LinkList; LinkList!(uint) list; void main(string[] args) { list = new LinkList!(uint); } In my tests, that code above doesn't produces the assertion failure, but my original source code looks very similar.
Mar 27 2011
nrgyzer:In my tests, that code above doesn't produces the assertion failure, but my original source code looks very similar.You may have to start over then. I suggest to duplicate the whole code, and then start on the copied version removing modules and lines of code, compiling it every time you remove something, making sure you keep seeing the error message every time, and undoing the change when you see the error vanish or change. Bye, bearophile
Mar 27 2011
== Auszug aus bearophile (bearophileHUGS lycos.com)'s Artikelnrgyzer:failure,In my tests, that code above doesn't produces the assertioncode, and then start on the copied version removing modules and lines of code, compiling it every time you remove something, making sure you keep seeing the error message every time, and undoing the change when you see the error vanish or change.but my original source code looks very similar.You may have to start over then. I suggest to duplicate the wholeBye, bearophileThat's a bit mysterious... I replaced firstModule with the source which produces the error. Now... when I run my test application, I get the same failure - but... that's not all - when I restore firstModule to the version which didn't produce the failure, I just get the same error. When I copy the source files to a new location and compile it, I didn't get the error. It seems that there is anything like a cache, but I removed all produced (obj, rsp...) files, expect the exe- and d-files. Thus I think there should be something like a cache. I currently haven't any idea what I can do to reproduce the failure efficently.
Mar 27 2011
nrgyzer wrote:Hey guys, I got "Assertion failure: '!vthis->csym' on line 703 in file 'glue.c'" after I add "LinkList!(uint) myList;" to my source file. I figured out that the same bug was already reported on http://lists.puremagic.com/ pipermail/digitalmars-d-bugs/2010-October/019237.html Ticket 4129 describes a bug in glue.c but for DMD 1.x and I'm using DMD 2.052.It's still the same bug. The source code for the backend is the same for all versions of DMD. The reported line number might change slightly (eg, might be line 691 on an old DMD version).
Mar 28 2011