Author Topic: find a new parsing tool (open sourced)- maybe can be integrated into CodeBlocks.  (Read 9978 times)

Offline wangdong1226

  • Multiple posting newcomer
  • *
  • Posts: 46
Dear CodeBlocks core developers,

I've found a new parsing tool -- Goldie, it is a series of flexible and comprehensive open-source parsing tools.

Goldie: http://www.semitwist.com/goldie

I know that codeblocks team will not spend too much time to produce a new parsing tool or engine for D languages or others, but please be kindly to look over this new parsing tool (engine) --- Goldie.

== Some of Goldie's benefits: (most are thanks to Goldie's compatibility with GOLD Parser Builder) ==

    - Grammars are fully-reusable: No need to create a new grammar for every use and every host language. Many grammars are already available.

    - Grammar-agnostic engine: One lexer/parser engine can be used for all grammars.

    - Engines for nearly any language or platform: A cross-platform D v2.x engine is included via GoldieLib. Engines for many other platforms are also available. New engines are easy to write.

    - Dynamic-Style: Dynamic-style lets you write programs that support user-created grammars.

    - Static-Style: Static-style provides compile-time checks and extra type-safety.

    - Lexing and parsing: Lexing and parsing are defined in the same file and handled by one unified tool.

    - Many tools available.

Goldie is fully-usable and has been tested on both Windows and Linux (it
should also work on OSX and any other platform supported by DMD, but has not
been tested), although GoldieLib's API is still subject to change. Goldie is
licensed under The zlib/libpng License.

I think, it also can be used or modified as C or C++ parser engine.
It is recommended that codeblocks team should evaluate it, and consider whether it's valued to integrate into CodeBlocks.


Sincerely yours,

David.

Offline oBFusCATed

  • Developer
  • Lives here!
  • *****
  • Posts: 13413
    • Travis build status
It is written in D, so it is pretty useless(unusable by) for C::B...
As far as I know there is no stable 64bit D compiler for Linux...
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]

Offline MortenMacFly

  • Administrator
  • Lives here!
  • *****
  • Posts: 9694
I know that codeblocks team will not spend too much time to produce a new parsing tool or engine for D languages or others, but please be kindly to look over this new parsing tool (engine) --- Goldie.
I doubt this will be easy (compatible). Did you notice that Goldie is written in D while C::B is written in C/C++?
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: https://www.codeblocks.org/docs/main_codeblocks_en.html
C::B FAQ: https://wiki.codeblocks.org/index.php?title=FAQ

Offline ollydbg

  • Developer
  • Lives here!
  • *****
  • Posts: 5910
  • OpenCV and Robotics
    • Chinese OpenCV forum moderator
Goldie: How To Use Goldie
from this page:
Quote
Goldie uses the LALR(1) and DFA algorithms to parse source. Both of these algorithms can be driven completely by tables of raw data, so Goldie requires grammars be compiled into these tables before they can be used. This provides certain benefits:

but c++ can not parsed by LALR(1) grammar, c++ need infinite look ahead, most c++ compiler use recursive descent parser (gcc, clang).
If some piece of memory should be reused, turn them to variables (or const variables).
If some piece of operations should be reused, turn them to functions.
If they happened together, then turn them to classes.

Offline wangdong1226

  • Multiple posting newcomer
  • *
  • Posts: 46
It is written in D, so it is pretty useless(unusable by) for C::B...
As far as I know there is no stable 64bit D compiler for Linux...

I don't think so.
Please view http://www.digitalmars.com/d/2.0/changelog.html

------
....
....
Under Construction

   1. Shared libraries for Linux

Version D 2.052 Feb 17, 2011
New/Changed Features

    * 64 bit support for Linux
    * Implemented exception chaining, as described in TDPL. Currently Windows-only.
    * std.random: Added Xorshift random generator
....
....
------

And I'm using this 64bit DMD compiler in my Fedora 14 x86_64 system via CodeBlocks.
I use CodeBlocks to compile the .d source file in 64bit, I got info:
------

---------------- Build: Release in DTraining ----------------
dmd -O -m64 -I/opt/dmd2/src/phobos -c _1_4_Arrays_64bit.d -ofobj/Release/_1_4_Arrays_64bit.o
gcc -lrt -o bin/Release/DTraining obj/Release/_1_4_Arrays_64bit.o   /opt/dmd2/linux/lib64/libphobos2.a -lpthread -lm
Output size is 762.96 KB

Process terminated with status 0 (0 minutes, 0 seconds)
0 errors, 0 warnings (0 minutes, 0 seconds)


------

BTW, now DMD2 version is dmd v2.053.

The latest versions and changes you can find here:
https://github.com/D-Programming-Language
« Last Edit: March 29, 2011, 03:15:41 am by wangdong1226 »