digitalmars.D - harmful null dereference straight in dmd
- Andrei Alexandrescu (14/14) Mar 07 2009 In what could be a supremely ironic turn, dmd has a null dereference
- Sean Kelly (4/20) Mar 07 2009 That's nasty. And it reminds me that I really need to try and figure
- Andrei Alexandrescu (9/30) Mar 07 2009 Exactly. This event reminds me of a funny story that happened a couple
In what could be a supremely ironic turn, dmd has a null dereference error that leaves me in the dust. I have to compile a largish D2 app that last compiled in 2007. I was thinking all I have to do is fix the language and compiler changes, which is what I was doing, until a point where dmd unceremoniously aborts compilation with: Segmentation fault This looks like a null dereference, and is the fourth time I am seeing writing should be, whenever you fail for whatever reason, inform the user about where you were. Trying to do forensics without such vital information wastes hours like minutes. If there was a need to convince me that null dereference can be harmful, this situation drove the point home in a rather painful way. Andrei
Mar 07 2009
Andrei Alexandrescu wrote:In what could be a supremely ironic turn, dmd has a null dereference error that leaves me in the dust. I have to compile a largish D2 app that last compiled in 2007. I was thinking all I have to do is fix the language and compiler changes, which is what I was doing, until a point where dmd unceremoniously aborts compilation with: Segmentation fault This looks like a null dereference, and is the fourth time I am seeing writing should be, whenever you fail for whatever reason, inform the user about where you were. Trying to do forensics without such vital information wastes hours like minutes. If there was a need to convince me that null dereference can be harmful, this situation drove the point home in a rather painful way.That's nasty. And it reminds me that I really need to try and figure out if file/line info can be reported for a segfault. Though I guess the larger issue is whether D should have a non-null attribute :-)
Mar 07 2009
Sean Kelly wrote:Andrei Alexandrescu wrote:Exactly. This event reminds me of a funny story that happened a couple of years ago. A radio talk show was discussing banning use of cell phones while driving. Some big wig politician calls the show and says, "I am driving right now and have no problem using my cell phone." Turns out the big wig subsequently did have an accident - that was heard on the show - ending that very dialog. I can't find that story, newer stories are covering it in google. AndreiIn what could be a supremely ironic turn, dmd has a null dereference error that leaves me in the dust. I have to compile a largish D2 app that last compiled in 2007. I was thinking all I have to do is fix the language and compiler changes, which is what I was doing, until a point where dmd unceremoniously aborts compilation with: Segmentation fault This looks like a null dereference, and is the fourth time I am seeing writing should be, whenever you fail for whatever reason, inform the user about where you were. Trying to do forensics without such vital information wastes hours like minutes. If there was a need to convince me that null dereference can be harmful, this situation drove the point home in a rather painful way.That's nasty. And it reminds me that I really need to try and figure out if file/line info can be reported for a segfault. Though I guess the larger issue is whether D should have a non-null attribute :-)
Mar 07 2009