Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
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).
Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
== Auszug aus David Nadlinger (s...@klickverbot.at)'s Artikel 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 I 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.
Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
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
Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
== Auszug aus bearophile (bearophileh...@lycos.com)'s Artikel 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 That'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.
Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
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!
Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
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
Re: Assertion failure: '!vthis-csym' on line 703 in file 'glue.c'
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