|
|
|
Oh, I thought the "usual" way to get around the expression restriction in lambdas was to use the compile() builtin:
>>> r = lambda: eval(compile("raise RuntimeError", '', 'exec'))
>>> r()
Traceback (most recent call last):
File "", line 1, in ?
File "", line 1, in
File "/usr/lib/python2.4/", line 1, in ?
RuntimeError
Using ctypes is impressively nasty here though 
Michael Hudson |
08/04/23 - 6:39 am | #
|
|
Am I the only one who, upon seeing the doit home page, read that as "doLt"? ;-D
Nicola Larosa |
Homepage |
08/04/24 - 9:32 am | #
|
|
|
Commenting by HaloScan
|