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/2016-April/143829.html below:

[Python-Dev] Question about the current implementation of str

[Python-Dev] Question about the current implementation of str [Python-Dev] Question about the current implementation of strLarry Hastings larry at hastings.org
Fri Apr 8 20:56:10 EDT 2016
I have a straightforward question about the str object, specifically the 
PyUnicodeObject.  I've tried reading the source to answer the question 
myself but it's nearly impenetrable.  So I was hoping someone here who 
understands the current implementation could answer it for me.

Although the str object is immutable from Python's perspective, the C 
object itself is mutable.  For example, for dynamically-created strings 
the hash field may be lazy-computed and cached inside the object.  I was 
wondering if there were other fields like this.  For example, are there 
similar lazy-computed cached objects for the different encoded versions 
(utf8 utf16) of the str?  What would really help an exhaustive list of 
the fields of a str object that may ever change after the object's 
initial creation.  Thanks!


We now return you to the debate about the pathlib module,


//arry/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20160408/b0c2638c/attachment.html>
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