[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-11-22 Thread Eric Snow


Eric Snow  added the comment:

I wouldn't worry about the c-analyzer stuff for now.  I plan on re-generating 
the file in the near future.

--
nosy: +eric.snow

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-11-16 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-11-16 Thread Dong-hee Na


Dong-hee Na  added the comment:

Looks like 
https://github.com/python/cpython/blob/088b63ea7a8331a3e34bc93c3b873c60354b4fad/Tools/c-analyzer/known.tsv#L1549
 should be updated also.
What do you think?

--
nosy: +corona10

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-11-16 Thread Serhiy Storchaka


Serhiy Storchaka  added the comment:


New changeset bd44a7ead9f7336d7bb45f186b2b6ca0300154f7 by Serhiy Storchaka in 
branch 'master':
bpo-38650: Constify PyStructSequence_UnnamedField. (GH-17005)
https://github.com/python/cpython/commit/bd44a7ead9f7336d7bb45f186b2b6ca0300154f7


--

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-10-30 Thread Serhiy Storchaka


Change by Serhiy Storchaka :


--
keywords: +patch
pull_requests: +16532
stage:  -> patch review
pull_request: https://github.com/python/cpython/pull/17005

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue38650] Add constantness to PyStructSequence_UnnamedField

2019-10-30 Thread Serhiy Storchaka


New submission from Serhiy Storchaka :

Currently the variable PyStructSequence_UnnamedField has type "char *". It is 
used as a special value for setting to the name field of 
PyStructSequence_Field. But the type of the name field is "const char *".

I propose to change the declaration of PyStructSequence_UnnamedField to "const 
char * const". Makes it referring to immutable character string and make it 
itself immutable.

It is binary compatible change, but some user code can complain at compilation 
time if it uses PyStructSequence_UnnamedField in unusual way (assigns to the 
"char *" variable, etc). It is very unlikely.

--
components: Interpreter Core
messages: 355731
nosy: serhiy.storchaka
priority: normal
severity: normal
status: open
title: Add constantness to PyStructSequence_UnnamedField
versions: Python 3.9

___
Python tracker 

___
___
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com