On 04.02.2016 19:35, Random832 wrote:
On Thu, Feb 4, 2016, at 11:18, Sven R. Kunze wrote:
On 04.02.2016 00:47, Random832 wrote:
On Wed, Feb 3, 2016, at 16:43, Sven R. Kunze wrote:
Actually a nice idea if there were no overhead of creating methods for
all heap instances separately. I'll keep th
On Thu, Feb 4, 2016, at 11:18, Sven R. Kunze wrote:
> On 04.02.2016 00:47, Random832 wrote:
> > On Wed, Feb 3, 2016, at 16:43, Sven R. Kunze wrote:
> >> Actually a nice idea if there were no overhead of creating methods for
> >> all heap instances separately. I'll keep that in mind. :)
> > What abo
On 04.02.2016 00:47, Random832 wrote:
On Wed, Feb 3, 2016, at 16:43, Sven R. Kunze wrote:
Actually a nice idea if there were no overhead of creating methods for
all heap instances separately. I'll keep that in mind. :)
What about changing the class of the object to one which is inherited
from i
On Wed, Feb 3, 2016, at 16:43, Sven R. Kunze wrote:
> Actually a nice idea if there were no overhead of creating methods for
> all heap instances separately. I'll keep that in mind. :)
What about changing the class of the object to one which is inherited
from its original class and has the method
On 03.02.2016 22:34, Bernardo Sulzbach wrote:
Did Peter's suggestion work?
Somewhat for a single Heap class.
However, it breaks inheritance.
--
https://mail.python.org/mailman/listinfo/python-list
On 03.02.2016 22:15, Peter Otten wrote:
The technical reason is that functions written in C don't implement the
descriptor protocol. The bound method is created by invoking the __get__
method of the class attribute:
Good to know. :-/
It's sad. These functions just look so method-like.
Bes
On 03.02.2016 22:19, Peter Otten wrote:
You could try putting
self.heappush = functools.partial(heapq.heappush, self)
into the initializer.
Actually a nice idea if there were no overhead of creating methods for
all heap instances separately. I'll keep that in mind. :)
--
https://mail.pytho
Did Peter's suggestion work?
--
https://mail.python.org/mailman/listinfo/python-list
On 03.02.2016 22:14, Bernardo Sulzbach wrote:
Thanks for quoting, for some reason my client always replies to the
person and not the list (on this list only).
I did what I could. I could show you a lambda function there, but it
doesn't solve anything. If there is a way to avoid a wrapper, I don'
Sven R. Kunze wrote:
> On 03.02.2016 22:06, Bernardo Sulzbach wrote:
>> I may say something wrong, but this is what I see going on:
>>
>> When you get "replace = heapreplace" you are creating a data attribute
>> called replace (you will access it by self.replace or
>> variable.replace) that is an
Thanks for quoting, for some reason my client always replies to the
person and not the list (on this list only).
I did what I could. I could show you a lambda function there, but it
doesn't solve anything. If there is a way to avoid a wrapper, I don't
know.
--
https://mail.python.org/mailman/list
Sven R. Kunze wrote:
> Hi,
>
> as you might have noticed, I am working on
> https://github.com/srkunze/xheap right now.
>
> In order to make it even faster and closer to heapq's baseline
> performance, I wonder if there is a possibility of creating fast
> wrappers for functions.
>
>
> Please c
On 03.02.2016 22:06, Bernardo Sulzbach wrote:
I may say something wrong, but this is what I see going on:
When you get "replace = heapreplace" you are creating a data attribute
called replace (you will access it by self.replace or
variable.replace) that is an alias for heapreplace.
When you cal
On 03.02.2016 21:40, Bernardo Sulzbach wrote:
I am not entirely sure about what your question is.
Are you talking about the "heapreplace expected 2 arguments, got 1"
you get if you set replace = heapreplace?
Yes, I think so.
I might ask differently: why do I need to write wrapper method when
I am not entirely sure about what your question is.
Are you talking about the "heapreplace expected 2 arguments, got 1"
you get if you set replace = heapreplace?
--
https://mail.python.org/mailman/listinfo/python-list
15 matches
Mail list logo