Change by Siddhesh Poyarekar :
--
nosy: +siddhesh
___
Python tracker
<https://bugs.python.org/issue47188>
___
___
Python-bugs-list mailing list
Unsubscribe:
Siddhesh Poyarekar added the comment:
Sorry I haven't had time to look into this since and it doesn't look like I'll
be able to get to it in the next couple of weeks. I had a couple of patches in
the github fork but they're pretty outdated and probably not even correct
Siddhesh Poyarekar added the comment:
> Pedantically the correct way is to cast to a function pointer with no
> prototype (empty parentheses) and from that to the target type. See for
> example. See for example https://godbolt.org/g/FdPdUj
This is one way that the gcc diagnostics e
Siddhesh Poyarekar added the comment:
Actually it is not; the parameter passed to Pythread_start_new_thread has a
different type (void (*)(void *)) from what's accepted (and executed by)
pthread_create (void *(*)(void *)). That is undefined beha
Siddhesh Poyarekar added the comment:
gcc8.1 throws this warning irrespective of the cast since converting function
pointers may result in undefined behaviour unless it is cast back to its
original type.
--
___
Python tracker
<ht
Siddhesh Poyarekar added the comment:
Yeah, there are multiple such uses that need wrappers to actually fix for gcc8,
which will be released this week. I think I'll have more time for some more
patches in this vein this weekend.
--
___
P
Siddhesh Poyarekar added the comment:
Fair enough, I'll reduce my scope of changes for this patchset, especially
since I'm unable to find enough time to work on the remaining changes I had
thought of in the coming weeks.
I'll post an update
Siddhesh Poyarekar added the comment:
I forgot to clarify that the function cast warning allows for variable argument
casts as a wildcard, which is my basis for the PyObject *(*)(PyObject *,
PyObject *, ...) fix proposal.
--
___
Python tracker
Siddhesh Poyarekar added the comment:
> The warning in GCC shouldn't probably have been enabled at all in `-Wall
> -Wextra` because the cast is explicit. However, it is somewhat true.
The explicit cast is precisely what enables the more nuanced function cast
warning where it
Siddhesh Poyarekar added the comment:
> I don't have GCC 8 so I cannot verify this bug, but *function pointer casts*
> are fine - any function pointer can be cast to any other function pointer -
> it is only that they must *not* be called unless cast back again to be
> co
New submission from Siddhesh Poyarekar :
gcc 8 has added a new warning heuristic to detect invalid function casts and a
stock python build seems to hit that warning quite often. bug 33012 fixes the
most trivial case of METH_NOARGS, this bug is to track a similarly trivial but
widely
Change by Siddhesh Poyarekar :
--
keywords: +patch
pull_requests: +5792
stage: -> patch review
___
Python tracker
<https://bugs.python.org/issue33012>
___
_
Change by Siddhesh Poyarekar :
--
keywords: +patch
pull_requests: +5773
stage: -> patch review
___
Python tracker
<https://bugs.python.org/issue33015>
___
_
New submission from Siddhesh Poyarekar :
The PyThread_start_new_thread function takes a void (*)(void *) as the function
argument, which does not match with the pthread_create callback which has type
void *(*)(void *). I've got a fix for this that adds a wrapper function of the
right
New submission from Siddhesh Poyarekar :
gcc 8 has added a new warning heuristic to detect invalid function casts and a
stock python build seems to hit that warning quite often. The most common is
the cast of a METH_NOARGS function (that uses just one argument) to a
PyCFunction. The fix is
Siddhesh Poyarekar added the comment:
It's not a change in glibc. __pthread_cond_timedwait is the internal function
name while pthread_cond_timedwait is the exported alias. You're seeing
__pthread_cond_timedwait here because either your glibc installation has debug
symbols or you
16 matches
Mail list logo