Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #35448 > unrolled thread

Re: Parsing files in python

Started byChris Angelico <rosuav@gmail.com>
First post2012-12-24 20:53 +1100
Last post2012-12-24 20:53 +1100
Articles 1 — 1 participant

Back to article view | Back to comp.lang.python

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: Parsing files in python Chris Angelico <rosuav@gmail.com> - 2012-12-24 20:53 +1100

#35448 — Re: Parsing files in python

FromChris Angelico <rosuav@gmail.com>
Date2012-12-24 20:53 +1100
SubjectRe: Parsing files in python
Message-ID<mailman.1246.1356342814.29569.python-list@python.org>
I'm hoping you meant for that to be public; if not, my apologies for
forwarding a private message.

On Mon, Dec 24, 2012 at 8:45 PM, Kene Meniru <kene.meniru@illom.org> wrote:
> Chris Angelico wrote:
>> from povray_macros import *
>>
>
> Am afraid you misunderstood my post. The file format I described is not an
> attempt to re-create or modify a python environment. I do not wish to be
> able to "import" python macros but other text files similar to the one I
> described.

Yep. There are two possibilities: Either you create a program that
reads in a file of format you invent, or you make a set of Python
functions and classes that mean that the format is actually a Python
script. Instead of writing a file parser, you use Python's, and the
program you write is actually a module rather than a top-level
application.

Producing output on stdout is one of the easiest and most standard
ways to export content.

ChrisA

[toc] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web