Alan Somers

Results 656 comments of Alan Somers

Cross-compilation could be solved by overriding the build script's platform detection. For example, on FreeBSD there's basically only one symbol that a build script would need to detect: `__FreeBSD_version`. When...

Not only does it not solve OpenBSD's use case; it doesn't solve the use case where operating systems make changes that _don't_ break the ABI. Both FreeBSD and Linux occasionally...

Good work @semarie. BTW, I've been studying ELF symbol versioning and I think it would be possible to fix libc without modifying Rust itself. Basically, libc would need to grow...

@semarie It's not just a BSD problem. Even glibc occasionally bumps the ELF symbol version of a function. Also, the version proliferation problem isn't quite as bad as you're thinking....

As the error message suggests, you can't do this on stable rust. You need a nightly compiler. See https://github.com/asomers/mockall/blob/master/mockall/tests/automock_foreign_c_variadic.rs .

Hearing no feedback, I assume that the poster was able to fix his problem by using a nightly compiler. Closing issue.

> I wonder if it would be possible to have the macro generate code such that the variadic functions wouldn't be available unless the unstable variadic feature was rnabled That's...

@gate2017aloy could you please provide some more information? A minimal example to reproduce the problem would be great. The example you provided can't even compile, because it doesn't include definitions...

That's still not a complete example. If you think that Mockall has a bug, could you please provide a _minimal_ example? That is, a self-contained example that doesn't rely on...

@samkottler's argument is correct. Currently, `#[concretize]` only works with a select few types: `T`, `&T`, `&mut T`, and `&[T]`. It could be made to work with `Option`, too. But working...