IonicWind Software

Aurora Compiler => General Discussion => Topic started by: Ionic Wind Support Team on October 27, 2005, 02:21:21 PM

Title: Making progress
Post by: Ionic Wind Support Team on October 27, 2005, 02:21:21 PM
Well I have cobbled together an IDE and Aurora has compiled its first "hello world" applicaiton.

The IDE uses the scintilla control so it has support for function folding and such.  Still a lot of work to do ;)
Title: Re: Making progress
Post by: Vikki on October 27, 2005, 03:01:31 PM
Sounds great! :)
Title: Re: Making progress
Post by: Steven Picard on October 28, 2005, 01:09:25 PM
Scintilla is definately the right choice. 

I'd like to see you include code regions (like in .NET). It's very handy to be able to do something like this for code folding:

// #REGION Comment History Box
/*
    Description: ....
    More Comments....
*/
// #ENDREGION Comment History Box


or

// #REGION Form Generation Code
    sub FormCreate
       etc...
    endsub

    sub FormHandler
       etc....
    endsub


    sub SomeOtherFormRelatedFunction
       etc....
    endsub
// #ENDREGION Form Generation Code
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 02, 2005, 03:33:34 PM
Scintilla really is a nice source editing component.  Even has column block selection by holding down the Alt key.  Something I use alot in other IDEs.

Just thought I would mention it.
Title: Re: Making progress
Post by: Sean on November 02, 2005, 04:17:16 PM
Wow! I can't believe how much you've got done already! Didn't think you could stay away from it long though :D
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 05, 2005, 02:22:32 PM
This was compiled successfully today ;)


class myclass {
declare function1(int a),int;
declare function2();
int a;
string b;
}

myclass :: function1(int a)
{
writeln(str$(this));
return 1;
}

myclass :: function2()
{
return;
}



Now to actually call the functions  ::)

Title: Re: Making progress
Post by: Steven Picard on November 05, 2005, 09:01:23 PM
I can't wait!!  ;D
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 06, 2005, 08:25:33 AM
The first class function was called last night at 4 am. :)   It referenced a class variable, modified it and printed it with another class function.

Fun stuff.

I held off on updating the alpha since I was on a roll. 

Title: Re: Making progress
Post by: GWS on November 06, 2005, 10:52:43 AM
Genius at work ..ÂÃ,  ::)

Graham
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 20, 2005, 10:23:58 PM
Getting closer to another alpha update.  Been swamped at work so not a lot of programming time.

NEW and DELETE are finished and handle classes properly.  Soon to have the first GUI functions working.

Still need more feedback/testers.  Only 8 of us involved right now which leaves a lot of room for things to be missed.

Paul.
Title: Re: Making progress
Post by: Zen on November 21, 2005, 06:35:31 AM
Another crash ;D


global sub main() {

openconsole();

writeln("Hello World");

closeconsole();

while getkey() = "";

return 0;
}


Putting the wait after the closeconsole function crashes the compiler instead of reporting an error.

Lewis
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 21, 2005, 06:44:09 AM
No crash here.  Compiles and does as expected....flickers the console for a moment.

Paul.
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 21, 2005, 06:45:54 AM
Of course that will leave the program running in memory, while it waits for input from a non-existant stream.  You have to open your task manager to kill it.

Paul.

Title: Re: Making progress
Post by: Zen on November 21, 2005, 07:16:14 AM
strange, it crashed before it compiled it here. It works now though, obviously like you said leaving it in memory.

Lewis
Title: Re: Making progress
Post by: Parker on November 21, 2005, 08:24:00 AM
The compiler crashes on this function:
sub GetWord(Document doc),pointer
{
// FIX THIS!
byte ch;
pointer tk;
unsigned int start;
start = doc.uPos;
ch = doc.*(string)pText[doc.uPos];
tk = _new(len(Token));
while (IsWord(ch))
{
doc.uPos++;
ch = doc.*(string)pText[doc.uPos];
}
*(token)tk.pValue = _new((doc.uPos-startpos)+1);
*(token)tk.*(string)pValue = mid$(doc.*(string)pText, startpos+1, doc.uPos - startpos);
*(token)tk.uLine = doc.uLine;
*(token)tk.uClass = TKWORD;
}

If I comment it out, it just reports errors about 'undeclared function GetWord'. I added the pointers types because I thought that was the problem which it has been before.

I've narrowed it down to three lines that it's having problems with:
//*(token)tk.pValue = _new((doc.uPos-startpos)+1);
//*(token)tk.*(string)pValue = mid$(doc.*(string)pText, startpos+1, doc.uPos - startpos);
//*(token)tk.uLine = doc.uLine;

If I comment those out it compiles fine.
Title: Re: Making progress
Post by: SnarlingSheep on November 21, 2005, 11:40:33 AM

unsigned int start;
start = doc.uPos;

You are calling this "startpos" later?
Title: Re: Making progress
Post by: Parker on November 21, 2005, 01:54:20 PM
 :-[ I guess I am... well, it should hurt my code, but it still crashes the compiler which isn't good. I'll have to fix that when I get home.
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 21, 2005, 02:22:40 PM
It's an alpha.  Expect a few crashes and roadblocks.

Will have fixed shortly ;)
Title: Re: Making progress
Post by: Ionic Wind Support Team on November 21, 2005, 02:31:21 PM
Your sub is also missing a 'return' statement
Title: Re: Making progress
Post by: Parker on November 21, 2005, 04:16:21 PM
Okay, got it to work with this:
sub GetWord(Document doc),pointer
{
byte ch;
pointer tk;
unsigned int start;
start = doc.uPos;
ch = doc.*(string)pText[doc.uPos];
tk = _new(len(Token));
while (IsWord(ch))
{
doc.uPos++;
ch = doc.*(string)pText[doc.uPos];
}
*(token)tk.pValue = _new((doc.uPos-start)+1);
*(token)tk.*(string)pValue = mid$(doc.*(string)pText, start+1, doc.uPos - start);
*(token)tk.uLine = doc.uLine;
*(token)tk.uClass = TKWORD;
return tk;
}

It doesn't seem to like pointers to strings, tokens, etc. I had to change the 'pText' member of Document to a pointer instead of string *. Also, the 'uLine' member didn't exist, which was probably causing a crash.
Title: Re: Making progress
Post by: GWS on November 22, 2005, 09:20:30 AM
Hey VS .. you'll be amazed to know, I can't figure out what the heck it says .. :)

Maybe understanding comes with practice ..

best wishes from a Basic person, :)

Graham
Title: Re: Making progress
Post by: Parker on November 22, 2005, 02:54:24 PM
The subroutine is supposed to extract a token from a piece of text. A lot of it is in other structures and subroutines, and unless you saw the whole source file, it would be hard to figure out what it means. A token contains a pointer for the value, its 'class' (word, number, string, operator, etc), and the line number. A document contains a lot of members, a couple are the length of the text, a pointer to the text, a list of tokens, the current position.

I just said I got it to compile. The program still doesn't run correctly. I'm rewriting it :)