Closed decoycom closed 7 years ago
This appears to be a bug in DMD. The sizes of the two types indeed do match up, but it still issues the error message.
The upcoming version 0.8.0 has this fixed, though, because it completely avoids the atomic operation.
Closing since 0.8.0 has been released with the workaround.
I got this error: (dmd2)\windows\bin....\src\druntime\import\core\atomic.d(1065,45): Error: cannot cast expression retVal of type ulong[2] to shared(HTTPServerContext)[] since sizes don't line up (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\http\server.d(1570,46): Error: template instance core.atomic.atomicLoad!(cast(MemoryOrder)3, shared(HTTPServerContext)[]) error instantiating
works fine with x86 😎
DUB version 1.3.0, built on Apr 10 2017 DMD32 D Compiler v2.074.0
I changed:
to: import vibe.d; //I can use import vibe.vibe; ...
code source: https://wiki.dlang.org/User:Csmith1991/Vibe.d_Documentation/websocket
Running (in (source)): (dmd2)\windows\bin\dub.exe build --arch=x86_64 --compiler=dmd --build-mode=allAtOnce --build=release Performing "release" build using dmd for x86_64. memutils 0.4.9: building configuration "secure"... Enhanced memory security is enabled. Memory debugger enabled libasync 0.8.3: building configuration "regular"... Enhanced memory security is enabled. Memory debugger enabled Using Windows message-based notifications and alertable IO for events vibe-d:utils 0.7.31: building configuration "library"... vibe-d:data 0.7.31: building configuration "library"... vibe-d:core 0.7.31: building configuration "libasync"... (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\core\drivers\libasync.d(33,8): Deprecation: module std.c.stdio is deprecated - Import core.stdc.stdio instead Enhanced memory security is enabled. Memory debugger enabled Using Windows message-based notifications and alertable IO for events (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\core\drivers\libasync.d(508,16): Deprecation: catch statement without an exception specification is deprecated; use catch(Throwable) for old behavior (dmd2)\windows\bin....\src\phobos\std\file.d(2638,12): Deprecation: function std.utf.toUTF8 is deprecated - To be removed November 2017. Please use std.utf.encode instead. (dmd2)\windows\bin....\src\phobos\std\file.d(2638,12): Deprecation: function std.utf.toUTF8 is deprecated - To be removed November 2017. Please use std.utf.encode instead. diet-ng 1.2.1: building configuration "library"... vibe-d:http 0.7.31: building configuration "library"... (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\core\drivers\libasync.d(33,8): Deprecation: module std.c.stdio is deprecated - Import core.stdc.stdio instead Enhanced memory security is enabled. Memory debugger enabled Using Windows message-based notifications and alertable IO for events (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\http\server.d(286,33): Deprecation: alias diet.traits.FilterCallback is deprecated - Use SafeFilterCallback instead. (dmd2)\windows\bin....\src\druntime\import\core\atomic.d(1065,45): Error: cannot cast expression retVal of type ulong[2] to shared(HTTPServerContext)[] since sizes don't line up (roaming)\dub\packages\vibe-d-0.7.31\vibe-d\source\vibe\http\server.d(1570,46): Error: template instance core.atomic.atomicLoad!(cast(MemoryOrder)3, shared(HTTPServerContext)[]) error instantiating dmd failed with exit code 1. Builder finished with result 2