A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2010-October/104949.html below:

[Python-Dev] MemoryError... how much memory?

[Python-Dev] MemoryError... how much memory? [Python-Dev] MemoryError... how much memory?Benjamin Peterson benjamin at python.org
Wed Oct 27 17:05:23 CEST 2010
2010/10/27 Facundo Batista <facundobatista at gmail.com>:
> There are a lot of places where Python or modules do something like:
>
>    self->buf = (char *)malloc(size);
>    if (!self->buf) {
>              PyErr_SetString(PyExc_MemoryError, "out of memory");
>
> At job, we're having some MemoryErrors, and one thing that we would
> love to know, if how much memory it was asking when that happened.

Isn't this usually when you do something like [None]*2**300? In that
case, wouldn't you know how much memory you're requesting?

Also, why is that useful?



-- 
Regards,
Benjamin
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4