View previous topic :: View next topic |
Author |
Message |
obijohn
Joined: 07 Feb 2006 Posts: 24
|
Posted: Tue Jan 08, 2008 5:48 am Post subject: goto next error? |
|
|
I just started using Descent. I've got it installed and working properly with the I20071218 Stream Integration build of Eclipse (except I use "bud" instead of "rebuild" for the External Tools compiler, which really shouldn't make a difference from what I can tell).
I must say that I absolutely love how it will identify syntax errors in your code, like a forgotten semi-colon, simply when saving a file without having to compile -- an extremely cool feature.
However, I can't seem to figure out how to jump to the line of an error that's reported when compiling. For example, if I don't have a return statement for main(), the Console window will report:
Code: |
testme.d(3): function testme.main expected to return a value of type int
|
In almost any editor I can expect to click on that type of error message and be taken to the location in the code where it's saying the error occurs. However, Descent doesn't do this. Is there a setting somewhere that enables this? |
|
Back to top |
|
|
asterite
Joined: 01 Jun 2006 Posts: 235 Location: Buenos Aires, Argentina
|
Posted: Tue Jan 08, 2008 6:42 am Post subject: |
|
|
Hi obijohn,
We're planning to release shortly a new version which will show you not only syntax errors as you type, but also semantic errors. Like JDT does.
And also go to definition, autocompletion, a good occurrences finder, evaluate compile-time functions, and more.
We already have most of this working, we just need to make sure everything works ok.
Just be patient a couple of weeks (months?).
Thanks for the feedback! |
|
Back to top |
|
|
obijohn
Joined: 07 Feb 2006 Posts: 24
|
Posted: Tue Jan 08, 2008 7:21 am Post subject: |
|
|
Yes, I've seen the video on upcoming features, and I'm super excited. D is a great language and deserves a great IDE, and I think Descent is going to be the one.
However, what I'm talking about is nothing so complex. It should be fairly easy to write a simple Eclipse plugin that just parses the Console output of the rebuild/bud external tool to place the cursor in the file and on the line indicated, shouldn't it? But I don't know, since I know nothing about writing Eclipse plugins.
Anyway, I'm really looking forward to where Descent is headed (which is UP, contrary to the name...) |
|
Back to top |
|
|
fraserofthenight
Joined: 08 Apr 2007 Posts: 33 Location: Seattle, WA
|
Posted: Thu Jan 10, 2008 12:38 am Post subject: |
|
|
I may write something like that for an intermediate build, since getting semantic error reporting right may take a while. |
|
Back to top |
|
|
obijohn
Joined: 07 Feb 2006 Posts: 24
|
Posted: Thu Jan 10, 2008 5:32 am Post subject: |
|
|
fraserofthenight wrote: | I may write something like that for an intermediate build, since getting semantic error reporting right may take a while. |
Oh thanks, that would really help a lot! |
|
Back to top |
|
|
Mahe
Joined: 23 Mar 2008 Posts: 4
|
Posted: Mon Jul 14, 2008 3:29 am Post subject: |
|
|
Hi,
I have edited the "Errorlink" plugin of the sunshade project, so that is also works with Eclipse 3.4. (Before it only works with Eclipse 3.2) http://sunshade.sourceforge.net/.
With "Errorlink" it is possible to get links to files in the output of the console. It is useful to jump to a position of an error, e.g:
[exec] src\test.d(502): found '}' when expecting ';' following 'statement'
(With the regex: \s*\[.*\]\s*(.*\.d)\((\d+)\).* )
Errorlink uses "consoleLineTracker" to listen to the console. Unfortunately, consoleLineTracker only works for predefined process types. Descent seems not to set a process type (Process type are specified via IProcess.ATTR_PROCESS_TYPE). So " Errorlink " only works, if you run for example "rebuild" via an Ant script.
I tried to find the location, where you create the console. But I was not successful. It would be nice if you could add an IProcess.ATTR_PROCESS_TYPE definition. So that one can also use errorlink for e.g. a debug (ddbg) session.
My "errorlink" project is available at:
http://www1.inf.tu-dresden.de/~s4254576/d/myerrorlink/ |
|
Back to top |
|
|
asterite
Joined: 01 Jun 2006 Posts: 235 Location: Buenos Aires, Argentina
|
Posted: Mon Jul 14, 2008 5:17 am Post subject: |
|
|
Hi Mahe,
Your project looks great. What would be nice, at least temporarily, is to make your plugin listen the output of an external tool such as rebuild or bud, without the need of doing it using an ant script.
I googled for a while but could find the process type of an external tool. Do they even have one?
I'll add a "descentDebugger" process type when launching the debugger. Why do you need that? The debugger already takes you to the line where it stopped. Anyway, if you want to try it, you can grab a copy from svn, it's line 575 of descent.debug.core.AbstractDescentLaunchConfigurationDelegate where the debugger process is created.
I'll use your project later in the day to see if it can get rebuild output to provide links to the sources. That would be awesome! |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|