Re: [Python-ideas] [off topic] Allow function to return multiple values

On Wed, Jul 5, 2017 at 11:34 AM, Chris Barker <chris.barker@noaa.gov> wrote:
[veering off-topic] I've implemented mutable integers as part of the gmpy2 library. The eXperimental MPZ (xmpz) type breaks many of the normal rules. Mutable
Direct access to individual bits
Iterating over bits
I'm not sure how useful it really is but it was fun to write. :) casevh

On Wed, Jul 5, 2017 at 12:48 PM, Case Van Horsen <casevh@gmail.com> wrote:
looks like you've added a lot more than mutability :-)
I'm not sure how useful it really is
Exactly -- when this comes up, I tend to think "I should make a mutable integer and put it on PyPi" -- but then I realize that the use case at hand is better handled another way. I have yet to encounter a use case where is seems like the best way to handle it. IT's mostly people trying to write C# (or another language) in Python :-) But a good exercise in writing code to emulate types in python.... -CHB -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chris.Barker@noaa.gov

On Wed, Jul 5, 2017 at 12:48 PM, Case Van Horsen <casevh@gmail.com> wrote:
looks like you've added a lot more than mutability :-)
I'm not sure how useful it really is
Exactly -- when this comes up, I tend to think "I should make a mutable integer and put it on PyPi" -- but then I realize that the use case at hand is better handled another way. I have yet to encounter a use case where is seems like the best way to handle it. IT's mostly people trying to write C# (or another language) in Python :-) But a good exercise in writing code to emulate types in python.... -CHB -- Christopher Barker, Ph.D. Oceanographer Emergency Response Division NOAA/NOS/OR&R (206) 526-6959 voice 7600 Sand Point Way NE (206) 526-6329 fax Seattle, WA 98115 (206) 526-6317 main reception Chris.Barker@noaa.gov
participants (2)
-
Case Van Horsen
-
Chris Barker