Question concerning Exceptions
Hi everyone, I have a question concerning the very basics of the D language: How can I read out the class name and the message string of Exception objects externally (that means with a program that accesses the main program's memory from outside)? I mean that I just have got a virtual pointer given via RaiseException()...and now I need some info where the classinfo object is and at which offset the member contents are located. It would be also helpful to give a structure format how objects are made of (--> structure table). Thanks in advance!
Re: Writing a language parser in D
Justin Johansson Wrote: > Can D people please recommend suitable tools for generating a parser (in D) > for an LL(1) grammar. There's bound to be much better parser generator tools > available nowadays, since my last foray into this area 10+ years ago with > YACC. I've heard of tools like bison, SableCC etc but apart from the names > know nothing about them. > > (Note. This question is not about writing a parser for D. It is about > writing a parser in D for another language which has an LL(1) grammar). > > Thanks in advance for all help. > > -- Justin Johansson > My D-IDE (written in C#) has an extra DLL which contains an entire D Parser...It's based on the SharpDevelop parser and lexer may you can use it www.alexanderbothe.com/?id=27
Re: My own IDE for D
I never receive any errors... May you could give me the trace log and the error message - that would help a lot...
Re: My own IDE for D
davidl Wrote: > �� Mon, 27 Jul 2009 08:01:13 +0800��BLS > �: > > > Alexander Bothe wrote: > >> Hey guys, I created a Windows-IDE for D! I know, It's not the best but > >> I'm still working on it! > >> Now there is a fully auto completion supported! > >> May someone of you could try it and say if it's working or not... > >> http://www.alexanderbothe.com/?id=27 > >> Requirements are only Windows with Framework v2 > >> > > > > Great !!! > > any plans to support automatic C# to D net converting ? > > > > > > > > Err, hacking Sharpdevelop C# -> VB.NET to produce D code is pretty easy. > I have one working converter. I successfully converted a simple proj of C# > to D.(around 1M source? i'm not quite sure). However, the proj doesn't > have very dense information. Just some simple protocal collecitons and > java beans like stuff + networking. > > The automatical part can help you add the import in D code(if a C# module > uses another module implicitly because of the namespace, it would help you > add this import in the output D file) > > It converts C# property to D style functions. > > It converts C# other minor differences to conform with the D syntax. > > It converts C# generic to D template. It converts C# generic contraint to > D2 contraint. > > It converts C# event to DFL style event. (i'm not quite sure, if i get it > correct, but after then, I find the project can be manually tweaked > without the automatical tools' aid.) > > It won't work if the C# code involes attributes which has substantial > import reference later. > It won't work if the C# code which uses PInvoke. Maybe it can be also > automatically translated to one .def file and corresponding binding. But > the C# proj I wanted to port doesn't contain such code. > > One possible improvement is automatically detect C# overload function hack > for faking default param, depends on how much effort you want to put on it. > > Even so, when I try to look at other C# code and take a chance of porting > them, I find it's tougher than what you think really. But maybe one would > figure it out later. > > Java looks pretty much closer to D. But the early effort of porting java > swt to d by some automatical tool is abandoned. Don't know the exact > reason, but porting from one language to another really requires lot of > effort. > > Convert D1 code to D2 is also pretty tough!! > > I hope the situation would change later. Your Idea isn't so bad, but why should a programmer translate his complete project into another language? I mean, when I've chosen Java, then I want to make Java:) and NOT D or C#...
Re: My own IDE for D
Dimitar Kolev Wrote: > Alexander Bothe Wrote: > > > Problem solved!!! I looked a bit around and there is written that I can > > search for these files in a custom directory! That sounds much better... > > Is it updated? Can we already download the new updates? > > :) > > Glad we are going to have one file of those in one directory. Sorry that I've forgotten to say that:) ...Yes, of course!
Re: My own IDE for D
Alexander Bothe Wrote: > Problem solved!!! I looked a bit around and there is written that I can > search for these files in a custom directory! That sounds much better... OK I've done it! Now the xshd files are parsed whereever your project is!
Re: My own IDE for D
Problem solved!!! I looked a bit around and there is written that I can search for these files in a custom directory! That sounds much better...
Re: My own IDE for D
Dimitar Kolev Wrote: > Alexander Bothe Wrote: > > > Great! OK let's see what I can do...the problem is that I cannot specify > > the path to the D.xshd explicitly... > > How about when you create a new project just pasting the file automatically > there. > > I do not care if the file is there but it will be irritating to put it > manually. That would make it very difficult to update these .xshd files if it's necessary. Besides, may I plan to support more languages (like xml) - Can you imagine to have all these xshd files in every project folder?
Re: My own IDE for D
Great! OK let's see what I can do...the problem is that I cannot specify the path to the D.xshd explicitly...
Re: My own IDE for D
No, the D-IDE.exe and all the other files are situated in my VS.NET Projects directory
Re: My own IDE for D
I added a style definition file for *.rc files now...may you could try a rc file first - I hope it works there... I also tested the D-IDE on my second PC on which Win XP runs - it works all well including the highlighting of D sources... mmmmay it's the thing with shells "current directory", that means if you selected another file, the Editor seeks the *.xshd files in the source directory
Re: My own IDE for D
And you're sure that the "D.xshd" is really in the directory where the D-IDE.exe is? For testing purposes, I renamed the "D.xshd" to "D.xshd_" - All highlighting was gone...I think that this must be the only reason...
Re: My own IDE for D
OK I added the missing "D.xshd" to the zip...may it works now:) To the parsing procedure: If you have a framework...like Phobos (I don't know if Tango will work)...you can add its base directory to the so called "parsing directories". Now, D-IDE will read every module's structure in the whole directory including its sub-directories and add these data to the global parsing cache - so you have the right environment for developing more faster and more efficient! I think this is also the way that all other IDEs go...correct me if I'm wrong
Re: My own IDE for D
OK I made the things with the compilers and build-tools as flexible as I could...now you can type the specific compiler executable and their arguments in the settings dialog... What do you mean with colors? The editor is based on the #develop editor - I just added a support for D syntax and D keyword highlighting... Isn't it enough?
Re: My own IDE for D
First, Thank you for your answers and for your ideas! I know there is still much to do but I'll do my best!
My own IDE for D
Hey guys, I created a Windows-IDE for D! I know, It's not the best but I'm still working on it! Now there is a fully auto completion supported! May someone of you could try it and say if it's working or not... http://www.alexanderbothe.com/?id=27 Requirements are only Windows with Framework v2