Message87360
| Author |
jyasskin |
| Recipients |
collinwinter, jyasskin |
| Date |
2009年05月07日.07:02:38 |
| SpamBayes Score |
5.4273638e-08 |
| Marked as misclassified |
No |
| Message-id |
<1241679764.04.0.154044942183.issue5954@psf.upfronthosting.co.za> |
| In-reply-to |
| Content |
Most uses of PyCode_Addr2Line
(http://www.google.com/codesearch?q=PyCode_Addr2Line) are just trying to
get the line number of a specified frame, but there's no way to do that
directly. Forcing people to go through the code object makes them know
more about the guts of the interpreter than they should need. The
proposed PyFrame_GetLineNumber provides a more obvious and direct way to
do the same thing.
If this goes in, we might be able to deprecate PyCode_Addr2Line
entirely. The uses of PyCode_Addr2Line that don't get the line of a
particular frame seem to be getting the line from a traceback (for
example,
http://www.google.com/codesearch/p?hl=en#u_9_nDrchrw/pygame-1.7.1release/src/base.c&q=PyCode_Addr2Line),
which is replaced by the tb_lineno field. |
|
History
|
|---|
| Date |
User |
Action |
Args |
| 2009年05月07日 07:02:44 | jyasskin | set | recipients:
+ jyasskin, collinwinter |
| 2009年05月07日 07:02:44 | jyasskin | set | messageid: <1241679764.04.0.154044942183.issue5954@psf.upfronthosting.co.za> |
| 2009年05月07日 07:02:42 | jyasskin | link | issue5954 messages |
| 2009年05月07日 07:02:41 | jyasskin | create |
|