Bug 18206 – Deprecate duplicated overloads in DRuntime

Status
NEW
Severity
normal
Priority
P3
Component
druntime
Product
D
Version
D2
Platform
x86_64
OS
All
Creation time
2018-01-08T01:01:29Z
Last change time
2024-12-07T13:37:55Z
Assigned to
No Owner
Creator
Seb
Moved to GitHub: dmd#17162 →

Comments

Comment #0 by greensunny12 — 2018-01-08T01:01:29Z
From https://github.com/dlang/dmd/pull/7577 DRuntime uses quite a bit of similar overloads of equal, bodyless function. If the workaround in https://github.com/dlang/dmd/pull/7577 is disabled, it errors with: src/core/sys/posix/signal.d(1720): Error: function core.sys.posix.signal.bsd_signal (int sig, extern (C) void function(int) nothrow @nogc func) cannot be overloaded with another extern (C) function at src/core/sys/posix/signal.d(1715) src/core/sys/posix/signal.d(1721): Error: function core.sys.posix.signal.sigset (int sig, extern (C) void function(int) nothrow @nogc func) cannot be overloaded with another extern (C) function at src/core/sys/posix/signal.d(1716) src/core/sys/posix/pthread.d(351): Error: function core.sys.posix.pthread.pthread_atfork (extern (C) void function() @nogc, extern (C) void function() @nogc, extern (C) void function() @nogc) cannot be overloaded with another extern (C) function at src/core/sys/posix/pthread.d(349) src/core/sys/posix/pthread.d(374): Error: function core.sys.posix.pthread._pthread_cleanup_push (_pthread_cleanup_buffer*, extern (C) void function(void*) nothrow @nogc, void*) cannot be overloaded with another extern (C) function at src/core/sys/posix/pthread.d(373) src/core/sys/posix/pthread.d(563): Error: function core.sys.posix.pthread.pthread_mutex_lock (shared(pthread_mutex_t)*) cannot be overloaded with another extern (C) function at src/core/sys/posix/pthread.d(562) src/core/sys/posix/pthread.d(565): Error: function core.sys.posix.pthread.pthread_mutex_trylock (shared(pthread_mutex_t)*) cannot be overloaded with another extern (C) function at src/core/sys/posix/pthread.d(564) src/core/sys/posix/pthread.d(567): Error: function core.sys.posix.pthread.pthread_mutex_unlock (shared(pthread_mutex_t)*) cannot be overloaded with another extern (C) function at src/core/sys/posix/pthread.d(566) An example: int pthread_mutex_lock(pthread_mutex_t*); int pthread_mutex_lock(shared(pthread_mutex_t)*); Another: void _pthread_cleanup_push(_pthread_cleanup_buffer*, _pthread_cleanup_routine, void*); void _pthread_cleanup_push(_pthread_cleanup_buffer*, _pthread_cleanup_routine_nogc, void*) @nogc;
Comment #1 by robert.schadek — 2024-12-07T13:37:55Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/17162 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB