botan icon indicating copy to clipboard operation
botan copied to clipboard

Build errors with DMD 2.100

Open p-mitana opened this issue 3 years ago • 1 comments

The errors for some reason are not present when building the botan itself, but I see them when I try to build a project using it.

Fedora 36 + DMD 2.100.

The project calls the following pieces:

  • RandomNumberGenerator.makeRng
  • generatePasshash9
  • checkPasshash9
../../botan/source/botan/tls/channel.d(574,13): Error: `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply` called with argument types `(int delegate(ref const(ushort) k, ref const(ConnectionCipherState) v) @system)` matches both:
../../memutils/source/memutils/hashmap.d(153,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(ref const(ushort), ref ConnectionCipherState) del)`
and:
../../memutils/source/memutils/hashmap.d(162,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(in ref ushort, in ref ConnectionCipherState) del) const`
../../botan/source/botan/tls/channel.d(580,13): Error: `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply` called with argument types `(int delegate(ref const(ushort) k, ref const(ConnectionCipherState) v) @system)` matches both:
../../memutils/source/memutils/hashmap.d(153,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(ref const(ushort), ref ConnectionCipherState) del)`
and:
../../memutils/source/memutils/hashmap.d(162,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(in ref ushort, in ref ConnectionCipherState) del) const`
../../botan/source/botan/tls/channel.d(839,9): Error: `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply` called with argument types `(int delegate(ref const(ushort) k, ref const(ConnectionCipherState) v) nothrow @system)` matches both:
../../memutils/source/memutils/hashmap.d(153,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(ref const(ushort), ref ConnectionCipherState) del)`
and:
../../memutils/source/memutils/hashmap.d(162,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(in ref ushort, in ref ConnectionCipherState) del) const`
../../botan/source/botan/tls/channel.d(844,9): Error: `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply` called with argument types `(int delegate(ref const(ushort) k, ref const(ConnectionCipherState) v) nothrow @system)` matches both:
../../memutils/source/memutils/hashmap.d(153,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(ref const(ushort), ref ConnectionCipherState) del)`
and:
../../memutils/source/memutils/hashmap.d(162,6):     `memutils.hashmap.HashMap!(ushort, ConnectionCipherState, ThreadMem).HashMap.opApply(int delegate(in ref ushort, in ref ConnectionCipherState) del) const`

Yes, I have cloned memutils – the latest tag won't build with the latest DMD, but the master will.

p-mitana avatar Jul 01 '22 18:07 p-mitana

It seems that there's actually a PR #59 for it.

p-mitana avatar Jul 01 '22 18:07 p-mitana

It should be fixed and tagged now

etcimon avatar Feb 22 '23 20:02 etcimon