> You code fail, see below for other comment
>
> Traceback (most recent call last):
> File "Download/pastie-2379978.rb", line 108, in
> make_template(template1)
> File "Download/pastie-2379978.rb", line 60, in make_template
> ast.fix_missing_locations(astFromSrc)
> File "/usr/lib/pyt
On Aug 17, 5:23 am, Irmen de Jong wrote:
> On 16-08-11 13:33, Paul Wray wrote:
>
>
>
>
>
>
>
>
>
> > The idea:
> > Python syntax allows a statement to be a bare literal or identifier.
> > These have no effect on the program.
>
> > So the function below is legal python:
>
> > def myFunc():
> > 'a'
"Paul Wray" wrote:
>
>Ive had what I think is a great idea for pure-python templates (I can almost
>hear the groans, bear with me...)
>...
>The idea:
>Python syntax allows a statement to be a bare literal or identifier. These
>have no effect on the program.
>...
>So is this (within the appropria
On Wed, Aug 17, 2011 at 12:57 AM, Paul Wray wrote:
> Thanks yes ama aware of docstrings but did not consider.
> They are easy to strip out though.
>
Maybe. You'd have to take notice of what's a docstring and what's the
first element to be outputted. Or alternatively, just forbid
docstrings on tho
On Aug 17, 2:14 am, Chris Angelico wrote:
> On Tue, Aug 16, 2011 at 12:33 PM, Paul Wray wrote:
> > The idea is simply to use python ASTs to transform this code so that it
> > accumulates the values of the bare expressions.
>
> That'd be similar to what the interactive loop does. Are you aware,
>
On 16-08-11 13:33, Paul Wray wrote:
The idea:
Python syntax allows a statement to be a bare literal or identifier.
These have no effect on the program.
So the function below is legal python:
def myFunc():
'a'
x = 45
'b'; 'c'; x
So is this (within the appropriate class context of course):
def
On Tue, Aug 16, 2011 at 12:33 PM, Paul Wray wrote:
> The idea is simply to use python ASTs to transform this code so that it
> accumulates the values of the bare expressions.
That'd be similar to what the interactive loop does. Are you aware,
though, that docstrings are bare expressions? You may
Hi all,
I did it. Finally managed to port mysqltuner.pl to python. Was a
real pain in the butt doing it from bottom up manually, without ever
really learing perl syntax. But i finally got it done. Now i need help
testing it. find it here.
g...@github.com:anandjeyahar/mysqlDbAdmin-python.git.
A
On 8/16/2011 7:33 AM, Paul Wray wrote:
Hello all
Ive had what I think is a great idea for pure-python templates (I can
almost hear the groans, bear with me...)
For the impatient, proof of concept is at http://pastie.org/2379978
demonstrating simple substitution, balanced tags using context mana
On Aug 16, 1:33 pm, "Paul Wray" wrote:
> Hello all
>
> Ive had what I think is a great idea for pure-python templates (I can almost
> hear the groans, bear with me...)
>
> For the impatient, proof of concept is athttp://pastie.org/2379978
> demonstrating simple substitution, balanced tags using co
Hello all
Ive had what I think is a great idea for pure-python templates (I can almost
hear the groans, bear with me...)
For the impatient, proof of concept is at http://pastie.org/2379978
demonstrating simple substitution, balanced tags using context manager,
subtemplates, and template inh
11 matches
Mail list logo