Re: Anouncing: Mike's Turbo Euphoria!

new topic     » goto parent     » topic index » view thread      » older message » newer message

Try
/* parser.c
   The big freakin' parsing machine...
   Pete Eberlein <xseal at harborside.com>
*/
Pete already has the code layed out.

The only significant enhancement your code will bring
is preprocessed information which anyone can write

The amount of math to be done will shorten
but, the pointers to sequences will not. On the fly
math procedures will not.

We already know that Euphoria's main stay are
sequences.

So tell me, what difference will this make?

euman

----- Original Message -----
From: "Jack Cat" <catjackus at YAHOO.COM>
To: <EUPHORIA at LISTSERV.MUOHIO.EDU>
Sent: Saturday, January 06, 2001 23:10 Euman
Subject: Re: Anouncing: Mike's Turbo Euphoria!


> > Heh, figures. Why do you do this? Do you really
> > think we believe all this
> > crap about your fancy IDE's and now this "Turbo
> > Euphoria" thing? You must
> > have some imagination, because you'll need a lot
> > more to figure out how
> > to actually WRITE these things...
> >
> >  - Matt
>
> Heh?
> WTF are you talking about man?
> I was just rewriting the main translation loop.
> Here is the source I was working on:
> -- TURBORIA.E
> -- The Euphoria In-Line Compiler
>
>
> -- By Mike The Spike
>
> without warning
>
> -- Standard Include Files
> include file.e
> include get.e
>
> -- ASM Include Files
> include asm.e
>
>
> sequence name, addr
> name = {}
> addr = {}
>
> function parse_string(sequence str)
> -- Parse Euphoria Code String Into Tokens ...
> object ret, word
> ret = {}
> word = ""
> for i = 1 to length(str) do
>         if str[i] = ',' or str[i] = ' ' or str[i] = '\t' or
> str[i] = '(' or str[i] = ')'
>            or str[i] = '+' or str[i] = '-' or str[i] = '*' or
> str[i] = '/' then
>                 ret = append(ret,word)
>                 ret = append(ret,str[i])
>                 word = ""
>         else
>                 word = word & str[i]
>         end if
> end for
> ret = append(ret,word)
> return ret
> end function
>
>
> global function new_func(sequence code)
> -- Compile Euphoria Code Into Machine Code
> object address, toks, asm
> toks = parse_string(code)
> asm = ""
>
> -- Translate to ASM
> for i = 1 to length(toks) do
>         if sequence(toks[i]) then
>                 if equal(toks[i],"integer") then
>                         for ix = i to length(toks) do
>                                 if atom(toks[ix]) then
>                                         if toks[ix] = '\n' then
>                                                 exit
>                                         end if
>                                 end if
>
> end for
>
> end function
>
> global procedure add_routine(sequence name)
> end procedure
>
>
> if sequence(new_func("procedure math(integer a,integer
> b)\n integer cp \n return a+b")) then end if
>
>
> Hehe, you can always try to beat me into writing this
> lib. Try to finish it before I do. This sounds like
> the kind of work Pete Eberlein would be great at.
> There's always the possibility I back out, like I
> ussualy do.
>
>
> Mike The Spike
>
> __________________________________________________
> Do You Yahoo!?
> Yahoo! Photos - Share your holiday photos online!
> http://photos.yahoo.com/
>

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu