Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #18615

Re: how to get id(function) for each function in stack?

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!gegeweb.org!de-l.enfer-du-nord.net!feeder2.enfer-du-nord.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <ian.g.kelly@gmail.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.019
X-Spam-Evidence '*H*': 0.96; '*S*': 0.00; 'attribute': 0.07; 'python': 0.08; 'stack,': 0.09; 'stack.': 0.09; 'subject:function': 0.16; 'cc:addr:python-list': 0.16; 'wrote:': 0.18; 'jan': 0.19; 'cc:no real name:2**0': 0.20; 'extension': 0.21; 'header:In-Reply-To:1': 0.22; 'objects,': 0.23; 'cc:2**0': 0.24; 'there.': 0.24; 'code': 0.25; 'function': 0.27; 'message- id:@mail.gmail.com': 0.28; 'cc:addr:python.org': 0.29; 'pm,': 0.29; 'subject:each': 0.30; 'subject:?': 0.31; "isn't": 0.33; 'there': 0.33; 'fri,': 0.34; 'received:209.85.212': 0.34; 'received:google.com': 0.37; 'received:209.85': 0.38; 'should': 0.39; 'subject:how': 0.39; 'received:209': 0.40; '2012': 0.67; '12:29': 0.84; 'build-in': 0.84; 'case?': 0.84
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; bh=Zg51rxFJAX77UWtTTM/Nzmwa081tDhXKq3BtmhEF6V4=; b=XzSsZPJLrnbcE1eME9HyyiyN3xM6YIZcrOTWoD0VoICRmdioxdtjuqMSudP7Gt4nMt fOFyxtPQdNdPvV6xE/lODr5xGJgl90MWQcdaE8so2QFeQ40zS6kVAVpTOicLNvjmUtgo 2z1dK6MWvBgpyVRfxeDb8N/akFuxJgXbswmco=
MIME-Version 1.0
In-Reply-To <9f8a8fd4-3541-4f9b-a887-3d10524de8f1@t30g2000vbx.googlegroups.com>
References <1002d4cd-6cfe-4b79-917f-361a06ffd215@a11g2000vbz.googlegroups.com> <mailman.4490.1325874536.27778.python-list@python.org> <9f8a8fd4-3541-4f9b-a887-3d10524de8f1@t30g2000vbx.googlegroups.com>
From Ian Kelly <ian.g.kelly@gmail.com>
Date Fri, 6 Jan 2012 12:50:43 -0700
Subject Re: how to get id(function) for each function in stack?
To dmitrey <dmitrey15@gmail.com>
Content-Type text/plain; charset=ISO-8859-1
Cc python-list@python.org
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.4491.1325879475.27778.python-list@python.org> (permalink)
Lines 7
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1325879475 news.xs4all.nl 6856 [2001:888:2000:d::a6]:54881
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:18615

Show key headers only | View raw


On Fri, Jan 6, 2012 at 12:29 PM, dmitrey <dmitrey15@gmail.com> wrote:
> Python build-in function sum() has no attribute func_code, what should
> I do in the case?

Built-in functions and C extension functions have no code objects, and
for that reason they also do not exist in the stack.  There is no way
to find sum() in the Python stack, because it isn't there.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

how to get id(function) for each function in stack? dmitrey <dmitrey15@gmail.com> - 2012-01-06 10:02 -0800
  Re: how to get id(function) for each function in stack? Ian Kelly <ian.g.kelly@gmail.com> - 2012-01-06 11:28 -0700
    Re: how to get id(function) for each function in stack? dmitrey <dmitrey15@gmail.com> - 2012-01-06 11:29 -0800
      Re: how to get id(function) for each function in stack? Ian Kelly <ian.g.kelly@gmail.com> - 2012-01-06 12:50 -0700
      Re: how to get id(function) for each function in stack? Dave Angel <d@davea.name> - 2012-01-06 14:56 -0500
      Re: how to get id(function) for each function in stack? Ian Kelly <ian.g.kelly@gmail.com> - 2012-01-06 13:37 -0700
      Re: how to get id(function) for each function in stack? Lie Ryan <lie.1296@gmail.com> - 2012-01-07 11:17 +1100
      Re: how to get id(function) for each function in stack? Robert Kern <robert.kern@gmail.com> - 2012-01-07 10:39 +0000
  Re: how to get id(function) for each function in stack? Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2012-01-07 00:54 +0000

csiph-web