Issue1609
Created on 2010-05-09.22:57:04 by hongdatang, last changed 2018-11-04.16:21:58 by jeff.allen.
msg5764 (view) |
Author: Hong Da Tang (hongdatang) |
Date: 2010-05-09.22:57:03 |
|
If you try to enter following code in the jython shell, you would receive error message, "SyntaxError: mismatched input '<EOF>' expecting CLASS".
def entryExit(f):
def new_f():
print "Entering", f.__name__
f()
print "Exited", f.__name__
return new_f
@entryExit
def func1():
print "inside func1()"
|
msg5772 (view) |
Author: Anthony Kong (akong) |
Date: 2010-05-21.20:55:42 |
|
I think it is not an issue anymore in branch Release_2_5rc4@7056
|
msg5793 (view) |
Author: Philip Jenvey (pjenvey) |
Date: 2010-06-03.02:32:16 |
|
I can reproduce this on trunk
|
msg5797 (view) |
Author: Anthony Kong (akong) |
Date: 2010-06-04.05:48:41 |
|
Seems like the problem is in the single_input() method of org.python.antlr.PythonParser. So, is it caused by incorrect anltr grammer?
|
msg11832 (view) |
Author: Jeff Allen (jeff.allen) |
Date: 2018-03-18.07:07:59 |
|
Not reproduced in 2.7.2a1 (entered a line at a time), so I infer that Frank fixed this at some point.
Jython 2.7.2a1+ (default:d74f8c2cd56f, Feb 24 2018, 17:18:53)
[Java HotSpot(TM) 64-Bit Server VM (Oracle Corporation)] on java1.8.0_151
Type "help", "copyright", "credits" or "license" for more information.
>>> def entryExit(f):
... def new_f():
... print "Entering", f.__name__
... f()
... print "Exited", f.__name__
... return new_f
...
>>> @entryExit
... def func1():
... print "inside func1()"
...
>>> func1()
Entering func1
inside func1()
Exited func1
>>>
|
|
Date |
User |
Action |
Args |
2018-11-04 16:21:58 | jeff.allen | set | status: pending -> closed |
2018-03-18 07:08:00 | jeff.allen | set | status: open -> pending resolution: remind -> fixed messages:
+ msg11832 nosy:
+ jeff.allen |
2013-02-27 17:46:48 | fwierzbicki | set | type: behaviour |
2013-02-27 17:46:28 | fwierzbicki | set | assignee: fwierzbicki resolution: remind versions:
+ Jython 2.7 |
2010-08-22 22:43:17 | zyasoft | set | priority: normal |
2010-06-16 19:21:54 | zyasoft | set | title: function decorator -> Partial parsing does not work with function decorators |
2010-06-04 05:48:43 | akong | set | messages:
+ msg5797 |
2010-06-03 02:32:17 | pjenvey | set | nosy:
+ pjenvey, fwierzbicki messages:
+ msg5793 |
2010-05-21 20:55:42 | akong | set | nosy:
+ akong messages:
+ msg5772 |
2010-05-09 22:57:04 | hongdatang | create | |
|