From 768360243aebbabebaf6baf50ac5659cb66474f9 Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Mon, 20 Jan 1997 04:26:20 +0000 Subject: [PATCH] Changes for frame object speedup: - get fastlocals differently - call newframeobject() with fewer arguments - toss getowner(), which was unused anyway --- Python/ceval.c | 16 ++-------------- 1 file changed, 2 insertions(+), 14 deletions(-) diff --git a/Python/ceval.c b/Python/ceval.c index a959e34814e..ea71c97d035 100644 --- a/Python/ceval.c +++ b/Python/ceval.c @@ -403,17 +403,14 @@ eval_code2(co, globals, locals, current_frame, /*back*/ co, /*code*/ globals, /*globals*/ - locals, /*locals*/ - owner, /*owner*/ - co->co_stacksize, /*nvalues*/ - CO_MAXBLOCKS); /*nblocks*/ + locals); /*locals*/ if (f == NULL) return NULL; current_frame = f; if (co->co_nlocals > 0) - fastlocals = ((listobject *)f->f_fastlocals)->ob_item; + fastlocals = f->f_localsplus; if (co->co_argcount > 0 || co->co_flags & (CO_VARARGS | CO_VARKEYWORDS)) { @@ -2129,15 +2126,6 @@ getglobals() return current_frame->f_globals; } -object * -getowner() -{ - if (current_frame == NULL) - return NULL; - else - return current_frame->f_owner; -} - object * getframe() {