Page 5 of 5 FirstFirst ... 2345
Results 161 to 168 of 168

Thread: Where is the Basic, in Visual Basic?

  1. #161
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Where is the Basic, in Visual Basic?

    Yes, I wrote everything with the exception of the syntax highlighting edit box. Actually the parsing for a BAT style program is so simple, each line starts with a command (or a colon for a label or comment) it can't start with anything else. You don't have assignment in the same manner as you do in "real" programming languages. With the exception of the IF statement and the FOR loop each line is a complete statement.

    I've written much more complex compilers than this. ScriptBrix for example use a VB-like language, allow you to create classes and instanciate objects and so on. This in comparison was a piece of cake and only took me about two days to write (with the exception of the help documentation).

  2. #162
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,600

    Re: Where is the Basic, in Visual Basic?

    Two days!! I am thoroughly impressed. I've dabbled in something similar in the past. I wrote a parser that deciphers a type of definition language that describes entities in a game and man it took some effort. Writer a proper parser is nothing trivial in my experience but then again I did it in VB6 which doesn't have all the string processing bells and whistles that VB.Net, or some C++ string library or class has.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  3. #163
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Where is the Basic, in Visual Basic?

    BatchBrix is written in Delphi 2010. The reason for that choice is because the BatchBrix compiler should be able to create EXE files without any dependencies on any other run-time libraries, such as the .Net libraries or the VB6 runtime. BatchBrix also just handles about 40 commands itself, the rest it simply direct to Windows command prompt interpretor, cmd.exe. Most of these commands are very simple to parse, the ones that are a bit more advanced is the FOR loop and the IF ... ELSE statement. Of course it must also parse out where all labels are for any GOTO or GOSUB call and then the following RETURN statement (yes BatchBrix supports GOSUB and RETURN). It also has its own variable stack apart from the Environment variables. So it must be able to parse out the values of variables, both those created by you in the script and the predefined ones that already exists (such as variables for the current directory, variables for the caret position and various named color constants).
    Last edited by Joacim Andersson; Nov 26th, 2012 at 04:12 PM.

  4. #164
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,600

    Re: Where is the Basic, in Visual Basic?

    I've always dreamed of doing something like this....my own scripting language. This is really good stuff. I'm curious, does Delphi expose its compiler in a similar manner as CodeDOM does in VB.Net ? You stated you needed BatchBrix's EXEs to be dependency free.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  5. #165
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Where is the Basic, in Visual Basic?

    No, Delphi does not expose its compiler but Delphi doesn't need dependencies. If I would have written my compiler in .Net I would still need the .Net framework for my compiled app.

  6. #166
    Angel of Code Niya's Avatar
    Join Date
    Nov 2011
    Posts
    8,600

    Re: Where is the Basic, in Visual Basic?

    Hmmm this is rather interesting. I'm trying to imagine how your compiler works....If you're not using an exposed Delphi compiler then I can only conclude that you wrote your very own native code generator or at least some kind of byte code compiler along with an interpreter. Either way, that is quite an accomplishment. The PE header itself is not all that complicated but I'm pretty sure writing an EXE takes some in-depth technical knowledge. You'd have to know some assembly at least. I remember reading up on that once and they went into all kinds talk about data segments and code segments and a whole lot of other low level technical stuff.
    Treeview with NodeAdded/NodesRemoved events | BlinkLabel control | Calculate Permutations | Object Enums | ComboBox with centered items | .Net Internals article(not mine) | Wizard Control | Understanding Multi-Threading | Simple file compression | Demon Arena

    Copy/move files using Windows Shell | I'm not wanted

    C++ programmers will dismiss you as a cretinous simpleton for your inability to keep track of pointers chained 6 levels deep and Java programmers will pillory you for buying into the evils of Microsoft. Meanwhile C# programmers will get paid just a little bit more than you for writing exactly the same code and VB6 programmers will continue to whitter on about "footprints". - FunkyDexter

    There's just no reason to use garbage like InputBox. - jmcilhinney

    The threads I start are Niya and Olaf free zones. No arguing about the benefits of VB6 over .NET here please. Happiness must reign. - yereverluvinuncleber

  7. #167
    I'm about to be a PowerPoster! Joacim Andersson's Avatar
    Join Date
    Jan 1999
    Location
    Sweden
    Posts
    14,649

    Re: Where is the Basic, in Visual Basic?

    It is an interesting subject but I guess we don't have to fill up this thread with it. I only throw BatchBrix in there since there was a discussion about batch programming.

  8. #168
    PowerPoster ThEiMp's Avatar
    Join Date
    Dec 2007
    Location
    Take The PCI Bus Across To The CPU!!
    Posts
    3,911

    Re: Where is the Basic, in Visual Basic?

    Quote Originally Posted by Joacim Andersson View Post
    This in comparison was a piece of cake and only took me about two days to write (with the exception of the help documentation).
    Please Note: It took me about four years to write Visual Suite SX and that it was only one Edition an then it still isn't so complete, that I can only release the Shareware Version of it over the Intenet. You as a programmer, totally rock!!

    Also that my Application, is a Visual Basic Source Code Editor, which makes it own source code data, then writes and then saves to the disk the document file, as Visual Basic code. Therefore my language is essentually a Code Editor. Then however the application is able to generate it's own source code, using a special techqine that was developed by me, at my computer programming firm. Then one that I am not going to mention, because I want to remain totally aniominous, and that is what it shall stay at. However the Help Documentation that I have been writing for the Application, only took about five days to write because as said before in this Thread, it is essentually a Visual Basic Source Code Editor, and nothing more...
    Last edited by ThEiMp; Nov 26th, 2012 at 10:28 PM.
    I have a huge free products range, of computer software in which you can download using any kind of 64-Bit Web Browser. Also there is coming a Social Networking section that I am making on my Website...

    |Ambra Productions Inc. | The Black Sun Society | The Black Shield | Ambra College | Church of the Black Sun | Ambra Productions Inc's Homepage | Boomtick Event's Venues: Ambar Nightclub, Jack Rabbit Slim's, Villa Nightclub and Lucy's Bar | Pasta Ambra | Fish Feast Company | Wallet Wizard | Ambrose Liquor | Ambar Tavern | Ambra University |

    Do you wish to do unpaid work for me??? If so, the PM me on this Forum, and then we can get to work, programming for the future of computers go by the name of ThEiMp. This is my ghost writers name. Also my nickname, means that I am: The Imperial of the Technology Industry, so then to make it really short, I just then wrote: The Imp, which is where I get the nickname from...

Page 5 of 5 FirstFirst ... 2345

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width