A RetroSearch Logo

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

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2006-July/067551.html below:

[Python-Dev] Strategy for converting the decimal module to C

[Python-Dev] Strategy for converting the decimal module to C [Python-Dev] Strategy for converting the decimal module to CGeorg Brandl g.brandl at gmx.net
Wed Jul 19 21:42:26 CEST 2006
Raymond Hettinger wrote:
> 
>>> I think it was tripping-up the folks working on the C implementation. 
>>> Georg can speak to it more directly.  IIRC, the issue was that the
>>> context object exposed a dictionary which a user could update directly
>>> and there was no notification back to the surrounding object so it could
>>> update an underlying bitfield representation.
>>>     
>>
>> Yes, that's exactly what the problem was. Working with bitfields internally
>> is fine as long as Python code doesn't want to change the dicts exposed
>> as a wrapper.
>>   
> 
> If you want to stick with dictionary-like access to traps and flags,
> then use a dict subclass that overrides each of the mutating methods.

That may be easiest to do in Python code. I'll leave it to Mateusz to decide.

> Even then, we need to drop the concept of having the flags as counters
> rather than booleans.

Yes. Given that even Tim couldn't imagine a use case for counting the
exceptions, I think it's sensible.

Georg

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