Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removal of stale code in _csv.c / pyexpat.c #45849

Closed
JosephArmbruster mannequin opened this issue Nov 27, 2007 · 2 comments
Closed

Removal of stale code in _csv.c / pyexpat.c #45849

JosephArmbruster mannequin opened this issue Nov 27, 2007 · 2 comments
Labels
extension-modules C modules in the Modules dir

Comments

@JosephArmbruster
Copy link
Mannequin

JosephArmbruster mannequin commented Nov 27, 2007

BPO 1508
Nosy @tiran

Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

Show more details

GitHub fields:

assignee = None
closed_at = <Date 2007-11-28.10:06:34.987>
created_at = <Date 2007-11-27.23:09:58.537>
labels = ['extension-modules']
title = 'Removal of stale code in _csv.c / pyexpat.c'
updated_at = <Date 2008-01-06.22:29:44.782>
user = 'https://bugs.python.org/JosephArmbruster'

bugs.python.org fields:

activity = <Date 2008-01-06.22:29:44.782>
actor = 'admin'
assignee = 'none'
closed = True
closed_date = <Date 2007-11-28.10:06:34.987>
closer = 'christian.heimes'
components = ['Extension Modules']
creation = <Date 2007-11-27.23:09:58.537>
creator = 'JosephArmbruster'
dependencies = []
files = []
hgrepos = []
issue_num = 1508
keywords = []
message_count = 2.0
messages = ['57895', '57908']
nosy_count = 2.0
nosy_names = ['christian.heimes', 'JosephArmbruster']
pr_nums = []
priority = 'normal'
resolution = 'fixed'
stage = None
status = 'closed'
superseder = None
type = None
url = 'https://bugs.python.org/issue1508'
versions = ['Python 3.0']

@JosephArmbruster
Copy link
Mannequin Author

JosephArmbruster mannequin commented Nov 27, 2007

I found two code blocks that look as if they can be safely removed:

From _csv.c:

/* begin 2.2 compatibility macros */
#ifndef PyDoc_STRVAR
/* Define macros for inline documentation. */
#define PyDoc_VAR(name) static char name[]
#define PyDoc_STRVAR(name,str) PyDoc_VAR(name) = PyDoc_STR(str)
#ifdef WITH_DOC_STRINGS
#define PyDoc_STR(str) str
#else
#define PyDoc_STR(str) ""
#endif
#endif /* ifndef PyDoc_STRVAR */

From pyexpat.c:

#ifndef PyDoc_STRVAR

/*
 * fdrake says:
 * Don't change the PyDoc_STR macro definition to (str), because
 * '''the parentheses cause compile failures
 * ("non-constant static initializer" or something like that)
 * on some platforms (Irix?)'''
 */
#define PyDoc_STR(str)         str
#define PyDoc_VAR(name)        static char name[]
#define PyDoc_STRVAR(name,str) PyDoc_VAR(name) = PyDoc_STR(str)
#endif

@JosephArmbruster JosephArmbruster mannequin added the extension-modules C modules in the Modules dir label Nov 27, 2007
@tiran
Copy link
Member

tiran commented Nov 28, 2007

Fixed in r59214
Thanks Joseph! Can you find more?

@tiran tiran closed this as completed Nov 28, 2007
@ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
extension-modules C modules in the Modules dir
Projects
None yet
Development

No branches or pull requests

1 participant