Author Topic: Something non-Chrono I made  (Read 743 times)

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2148
  • 7th Elemental Innate, and vtuber
    • View Profile
Something non-Chrono I made
« on: August 28, 2010, 12:02:24 am »
I am in production of my own programming language. I didn't originally make it but it was abandoned in early development so I'm remaking it and finishing it.

Check out the code repo: http://github.com/Schala/Zeal-KL

It's almost ready for an early alpha, but it will only do variables and commands when released. Alpha is alpha though. It's not complete.

ZaichikArky

  • Mystical Knight (+700)
  • *
  • Posts: 718
    • View Profile
    • Livejournal
Re: Something non-Chrono I made
« Reply #1 on: August 28, 2010, 04:05:54 am »
What could it be used for?

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2148
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: Something non-Chrono I made
« Reply #2 on: August 28, 2010, 05:31:19 am »
Well I wanted a language that can be almost completely customized and extended while having powerful features like macros and user-friendliness and object-orientation the right way.

Code: [Select]
module Example;
    class Thread, super ForumObject;
        var id, uint16;
        var name, Text;
        var moderators, array User;
        var hitCount, uint32;
    eclass;

    cmd makeNewThread;
        prm thread, ptr Thread;
        prm name, Text;
 
        thread = new Thread, (0, "General Discussion", (Zeality, Ramsus), 9000);
    ecmd;
emodule;

idioticidioms

  • Guest
Re: Something non-Chrono I made
« Reply #3 on: August 28, 2010, 09:04:37 am »
hey, I can actually understand that better than php.

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2148
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: Something non-Chrono I made
« Reply #4 on: August 28, 2010, 06:56:03 pm »
^_^ Well it isn't a web language like PHP but I suppose I can make it convert into Java. My main target is software programs. I just used the forums as an example.

Ramsus

  • Entity
  • Chronopolitan (+300)
  • *
  • Posts: 313
    • View Profile
Re: Something non-Chrono I made
« Reply #5 on: August 29, 2010, 10:01:00 am »
Seems kind of early to announce an upcoming alpha, isn't it? You've only written one barebones function to tokenize strings, and then some random skeleton code so far.

If you're looking for quick results (and you should be, so you can test out and prototype your ideas faster), GNU Bison and Ragel are excellent tools. Ragel is particularly interesting, since it has a lot of different applications and generates code in multiple languages without any dependencies.


Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2148
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: Something non-Chrono I made
« Reply #6 on: August 29, 2010, 10:52:44 am »
I actually looked into Bison but it looks difficult plus some of my coding buddies said it was unnecessarily complex.

I'm sort of redoing the code for KL's compiler. I felt I could make it better than what I originally wrote. I stopped last night and thought "I could do this better."

My idea is having everything structure. Like, for variables, there'd be a structure with the members identifier, type, and value. That way when doing the codegen, it'd be easier to build. I'm thinking of using an ID system so everything's generated in the correct order. Maybe tonight I'll have the new branch up.

Schala Zeal

  • Radical Dreamer (+2000)
  • *
  • Posts: 2148
  • 7th Elemental Innate, and vtuber
    • View Profile
Re: Something non-Chrono I made
« Reply #7 on: September 01, 2010, 06:04:55 am »
Okay, I redid a good portion of KL's implementation to make it far less complicated for working on. Github hosts the latest code as of tonight and if it works well, it'll be easier for me to add more features like object-orientation and macros in the future.

A sub-project I want to do is KLScript, a stack-based scripting language for the purpose of embedded scripting. That will hopefully come once KL manages to bootstrap. By that I mean eventually I want to write KL in itself.