__getattr__ functionality for modules?

Bryan belred1 at yahoo.com
Mon May 26 16:10:05 EDT 2003


> What I'm trying to realize is a small domain specific configuration
> language: A subset of Python that consists of nothing else but
>
> - a couple of functions,
>
> - the ability to define your own functions with 'def' with correct scope
nesting
>
> - Python's numeric expressions
>
> - and an (unlimited) number of builtin constants. That's what I need
>   the module getattr hook for
>
> This is absolutely trivial to learn for the users in my context. Using
> objects and attributes here adds an unnecessary (and unwanted)
> level of complexity.
>
>
> Stefan
>
>

this sounds exactly what lua was designed for and might be a bit easier to
achieve what you want.
http://www.lua.org/

bryan






More information about the Python-list mailing list