Re: [BangPypers] Language Parsing and output generation

2011-08-22 Thread Balachandran Sivakumar
Hi, On Tue, Aug 23, 2011 at 12:39 AM, Gopalakrishnan Subramani wrote: > > The idea is to convert the 'Description Language' code to Lua code using > Python. This involves 2 things. One is parsing and another is generation. In > between 2, I need to make a tree as a output from parser, kind of AST

Re: [BangPypers] Language Parsing and output generation

2011-08-22 Thread Gopalakrishnan Subramani
I could make a grammar compiled myself. I will look into SPARK.. Anybody has experience in pyparsing http://pyparsing.wikispaces.com/ ? Under Examples http://pyparsing.wikispaces.com/Examples Python language example is promising. Regards, Gopal On Mon, Aug 22, 2011 at 11:25 PM, Noufal Ibrahim

Re: [BangPypers] Language Parsing and output generation

2011-08-22 Thread Noufal Ibrahim
Gopalakrishnan Subramani writes: > Source language IO is very limited and it has functions to map to IO and UI. > As a total, they have around 100+ function. > > Those can be easily done in Lua. [...] For a project in one of my earlier companies, I used SPARK[1] to write a little parser for a l

Re: [BangPypers] Language Parsing and output generation

2011-08-22 Thread Gopalakrishnan Subramani
Source language IO is very limited and it has functions to map to IO and UI. As a total, they have around 100+ function. Those can be easily done in Lua. -- Gopal On Mon, Aug 22, 2011 at 6:10 PM, Senthil Kumaran wrote: > On Mon, Aug 22, 2011 at 01:09:19PM -0600, Gopalakrishnan Subramani wrote

Re: [BangPypers] Language Parsing and output generation

2011-08-22 Thread Senthil Kumaran
On Mon, Aug 22, 2011 at 01:09:19PM -0600, Gopalakrishnan Subramani wrote: > I prefer Python for this conversion. Any idea is appreciated. In your source language, do you have tools to create AST? If not, then it would be the first thing to aim for. Then you need a mechanism to translate that AST t

Re: [BangPypers] Create Better Python community

2011-08-22 Thread Senthil Kumaran
On Fri, Aug 19, 2011 at 05:59:37PM +0530, Kenneth Gonsalves wrote: > > > > > > on several occasions we had 2 > > > > > > > I dont call that a user group meeting. That is definitely > > apathy though better than no meeting any day. > > it works And yes, that is what is required. So, regular sc

[BangPypers] Language Parsing and output generation

2011-08-22 Thread Gopalakrishnan Subramani
I have interesting problem to solve. We have a language called "Description Language" less widely known outside but used very much in automation domain. The examples are given below. By definition, language is readable and I could could not provide the language spec due to restriction (really close