homepage

This issue tracker has been migrated to GitHub , and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author Albert.Zeyer
Recipients Albert.Zeyer, vstinner
Date 2011年07月22日.13:52:29
SpamBayes Score 0.024971828
Marked as misclassified No
Message-id <1311342749.88.0.097321669624.issue12609@psf.upfronthosting.co.za>
In-reply-to
Content
Simplified code:
```
from ast import *
globalsDict = {}
exprAst = Interactive(body=[
	FunctionDef(
		name=u'foo',
		args=arguments(args=[], vararg=None, kwarg=None, defaults=[]),
		body=[Pass()],
		decorator_list=[])])
fix_missing_locations(exprAst)
compiled = compile(exprAst, "<foo>", "single")
eval(compiled, {}, globalsDict)
f = globalsDict["foo"]
print(f)
```
If I change `name=u'foo'` to `name='foo'`, it works.
History
Date User Action Args
2011年07月22日 13:52:29Albert.Zeyersetrecipients: + Albert.Zeyer, vstinner
2011年07月22日 13:52:29Albert.Zeyersetmessageid: <1311342749.88.0.097321669624.issue12609@psf.upfronthosting.co.za>
2011年07月22日 13:52:29Albert.Zeyerlinkissue12609 messages
2011年07月22日 13:52:29Albert.Zeyercreate

AltStyle によって変換されたページ (->オリジナル) /