[BangPypers] python for parsing
Hello everyone , I am new to this community . recently i attended a python workshop in my college and got a lot mesmerised by the language so finally decided to port my mini project which i have partially written using LEX and Yacc into python. i would be glad if you could provide me some valuable suggestions on how to go about doing so. Thanking You Rahul ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
On Mon, May 24, 2010 at 12:51 AM, Rahul R wrote: > Hello everyone , > I am new to this community . recently i attended a python workshop in my > college and got a lot mesmerised by the language so finally decided to port > my mini project which i have partially written using LEX and Yacc into > python. i would be glad if you could provide me some valuable suggestions on > how to go about doing so. there are literally tons of options - Here's a good list - http://nedbatchelder.com/text/python-parsers.html I've had good experiences with the SPARK http://pages.cpsc.ucalgary.ca/~aycock/spark/ library. Very Pythonic. None of the Yacc/Lex boilerplate. -- ~noufal http://nibrahim.net.in ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
On Mon, May 24, 2010 at 12:51 AM, Rahul R wrote: > Hello everyone , > I am new to this community . recently i attended a python workshop in my > college and got a lot mesmerised by the language so finally decided to port > my mini project which i have partially written using LEX and Yacc into > python. i would be glad if you could provide me some valuable suggestions > on > how to go about doing so. > > I had once found pyparsing http://pyparsing.wikispaces.com/ quite nice though I used it in a casual experiment. I had documented my usage here : http://codeblog.dhananjaynene.com/2010/01/extracting-data-using-recursive-descent-parsing/which hopefully should indicate how its usage is in many ways far simpler than traditional lex/yacc one. Dhananjay > > Thanking You > Rahul > ___ > BangPypers mailing list > BangPypers@python.org > http://mail.python.org/mailman/listinfo/bangpypers > -- blog: http://blog.dhananjaynene.com twitter: http://twitter.com/dnene ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
On Mon, May 24, 2010 at 12:00 AM, Dhananjay Nene wrote: > On Mon, May 24, 2010 at 12:51 AM, Rahul R wrote: > > > Hello everyone , > > I am new to this community . recently i attended a python workshop in my > > college and got a lot mesmerised by the language so finally decided to > port > > my mini project which i have partially written using LEX and Yacc into > > python. i would be glad if you could provide me some valuable suggestions > > on > > how to go about doing so. > > > > I had once found pyparsing http://pyparsing.wikispaces.com/ quite nice > though I used it in a casual experiment. > > I had documented my usage here : > > http://codeblog.dhananjaynene.com/2010/01/extracting-data-using-recursive-descent-parsing/which > hopefully should indicate how its usage is in many ways far simpler > than traditional lex/yacc one. > > Dhananjay > > > Thanks Dhananjay & Noufal , now i have tons of options. But then again i am trying to find the most suitable one for my program. Well basically what i am trying to achieve is to create my own syntax (reasonably simple ) which will help the user to write simple HTML ( +CSS hopefully) pages without actually coding any of it . i.e for example if the user writes this is heading --> { the '=' would be a token for headers } the rest paragraph the equivalent html generated could be this is heading the rest paragraph besides i am also trying to incorporate inline CSS and other basic functualities . ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
Hi, Rahul It looks like you are trying to create an abstraction above the HTML+JS etc. Have you looked at pyjamas pyjs.org ? Though GWT uses java for the same thing. On Mon, May 24, 2010 at 2:02 AM, Rahul R wrote: > On Mon, May 24, 2010 at 12:00 AM, Dhananjay Nene > wrote: > > > On Mon, May 24, 2010 at 12:51 AM, Rahul R wrote: > > > > > Hello everyone , > > > I am new to this community . recently i attended a python workshop in > my > > > college and got a lot mesmerised by the language so finally decided to > > port > > > my mini project which i have partially written using LEX and Yacc into > > > python. i would be glad if you could provide me some valuable > suggestions > > > on > > > how to go about doing so. > > > > > > I had once found pyparsing http://pyparsing.wikispaces.com/ quite nice > > though I used it in a casual experiment. > > > > I had documented my usage here : > > > > > http://codeblog.dhananjaynene.com/2010/01/extracting-data-using-recursive-descent-parsing/which > > hopefully should indicate how its usage is in many ways far simpler > > than traditional lex/yacc one. > > > > Dhananjay > > > > > > > Thanks Dhananjay & Noufal , now i have tons of options. But then again i > am trying to find the most suitable one for my program. > Well basically what i am trying to achieve is to create my own syntax > (reasonably simple ) which will help the user to write simple HTML ( +CSS > hopefully) pages without actually coding any of it . > > i.e for example > > if the user writes > > this is heading > --> { the '=' would be a token for headers } > > the rest paragraph > > > the equivalent html generated could be > > this is heading > the rest paragraph > > besides i am also trying to incorporate inline CSS and other basic > functualities . > ___ > BangPypers mailing list > BangPypers@python.org > http://mail.python.org/mailman/listinfo/bangpypers > -- regards --- Kunal Ghosh Dept of Computer Sc. & Engineering. Sir MVIT Bangalore,India Blog:kunalghosh.wordpress.com Website:www.kunalghosh.net46.net ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
Thanks Kunal , i am happy as well as sad , happy because my job has become much simpler and sad because everytime i think of a novel (honeslty ) idea .. i see someone else has already executed it .. :( On Mon, May 24, 2010 at 5:02 AM, kunal ghosh wrote: > Hi, Rahul > It looks like you are trying to create an abstraction above the HTML+JS > etc. > Have you looked at pyjamas pyjs.org ? > Though GWT uses java for the same thing. > > On Mon, May 24, 2010 at 2:02 AM, Rahul R wrote: > > > On Mon, May 24, 2010 at 12:00 AM, Dhananjay Nene > > wrote: > > > > > On Mon, May 24, 2010 at 12:51 AM, Rahul R wrote: > > > > > > > Hello everyone , > > > > I am new to this community . recently i attended a python workshop in > > my > > > > college and got a lot mesmerised by the language so finally decided > to > > > port > > > > my mini project which i have partially written using LEX and Yacc > into > > > > python. i would be glad if you could provide me some valuable > > suggestions > > > > on > > > > how to go about doing so. > > > > > > > > I had once found pyparsing http://pyparsing.wikispaces.com/ quite > nice > > > though I used it in a casual experiment. > > > > > > I had documented my usage here : > > > > > > > > > http://codeblog.dhananjaynene.com/2010/01/extracting-data-using-recursive-descent-parsing/which > > > hopefully should indicate how its usage is in many ways far simpler > > > than traditional lex/yacc one. > > > > > > Dhananjay > > > > > > > > > > > Thanks Dhananjay & Noufal , now i have tons of options. But then again > i > > am trying to find the most suitable one for my program. > > Well basically what i am trying to achieve is to create my own syntax > > (reasonably simple ) which will help the user to write simple HTML ( +CSS > > hopefully) pages without actually coding any of it . > > > > i.e for example > > > > if the user writes > > > > this is heading > > --> { the '=' would be a token for headers } > > > > the rest paragraph > > > > > > the equivalent html generated could be > > > > this is heading > > the rest paragraph > > > > besides i am also trying to incorporate inline CSS and other basic > > functualities . > > ___ > > BangPypers mailing list > > BangPypers@python.org > > http://mail.python.org/mailman/listinfo/bangpypers > > > > > > -- > regards > --- > Kunal Ghosh > Dept of Computer Sc. & Engineering. > Sir MVIT > Bangalore,India > > Blog:kunalghosh.wordpress.com > Website:www.kunalghosh.net46.net > ___ > BangPypers mailing list > BangPypers@python.org > http://mail.python.org/mailman/listinfo/bangpypers > ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers
Re: [BangPypers] python for parsing
On Mon, May 24, 2010 at 12:06 PM, Rahul R wrote: > Thanks Kunal , i am happy as well as sad , happy because my job has become > much simpler and sad because everytime i think of a novel (honeslty ) idea > .. i see someone else has already executed it .. :( There are still lots of things to do. Read the other code and learn from it, perhaps implement your own thing and compare it with the other to see if there are things to learn. Reinventing the wheel is usually pointless but as an educational experience, I think it's nice. -- ~noufal http://nibrahim.net.in ___ BangPypers mailing list BangPypers@python.org http://mail.python.org/mailman/listinfo/bangpypers