Sane API design (AKA C's #ifdef hell)
Richard (Rikki) Andrew Cattermole
richard at cattermole.co.nz
Fri Apr 17 14:40:28 UTC 2026
On 18/04/2026 2:33 AM, Dennis wrote:
> On Friday, 17 April 2026 at 13:51:58 UTC, Adam D. Ruppe wrote:
>> tbh though instead of versioning symbols i'd rather they be like
>> marked... better to say "function foo was introduced in version 4.4
>> but you are using 4.3 compatibility flags" rather than "undefined
>> symbol: foo"
>
> Perhaps adding a bool and string argument to the `@disabled(b, "needs
> version 4.3")` attribute?
Given that it doesn't support string either, I'd suggest we bring it to
the meeting for approval.
Looks like an easy win.
More information about the Digitalmars-d
mailing list