2013/3/14 Maciej Fijalkowski <[email protected]> > On Thu, Mar 14, 2013 at 2:18 PM, Dzhelil Rufat <[email protected]> wrote: > > I just found out about a new feature in python that allows you to do > > function annotations like below: > > > > def greet(name: str, age: int) -> str: > > print('Hello {0}, you are {1} years old'.format(name, age)) > > > > > > See this link for a more detailed description: > > > http://ceronman.com/2013/03/12/a-powerful-unused-feature-of-python-function-annotations/ > > > > Are there any plans to incorporate this feature into rpython? > > > > I presume this would make the static analysis in rpython significantly > > easier, and would speed up the compilation process? > > There are various plans about enforcing types more strictly in > RPython. Using *this* precise syntax is one of the options, but this > is not the problem. The problem is making expressive enough object > model. Also, putting work into that. >
The annotation syntax is only available in Python 3, and RPython is still defined on top of Python 2. -- Amaury Forgeot d'Arc
_______________________________________________ pypy-dev mailing list [email protected] http://mail.python.org/mailman/listinfo/pypy-dev
