Feature request: function prototypes

BCS BCS at pathlink.com
Fri Feb 8 11:05:31 PST 2008


Ary Borenszweig wrote:

> 
> But unittests are run with specific version flags.
> 
> I think he means something like this:
> 
> ---
> prototype {
>   int someFunc(float, bool);
> }
> 
> version(one) {
>   int someFunc(float f, bool b) {
>     // ...
>   }
> } else {
>   int someFunc(float f, bool b) {
>     // ...
>   }
> }
> ---


To get the full advantage of this you would need to be able to run the 
compiler with "wrong" versions. e.g. on windows, run the compile up to 
the code generation phase with the Linux versions set. This in and of 
it's self might be handy.



More information about the Digitalmars-d mailing list