A crate to parametrize compile-time conditionals?

I have seen a crate to parametrize compile-time conditionals, but I lost it.
It makes possible to express complex conditionals like that below once and then reuse it.

  cfg( all
    not( all( feature = "default_ops", feature = "nalgebra" ) ),
    any( feature = "default_ops", feature = "nalgebra" ),

Please remind me.

cfg-if https://crates.io/crates/cfg-if ?

1 Like

Thank you. Although it seems cfg-if does not allow to create an alias and use alias instead of retyping whole conditional.


1 Like

Awesome! That what I have been looking for.
Do you think it has low impact on compile-time?

I can't tell.
It might be worth checking out how to do a benchmark for compile time.

1 Like

This topic was automatically closed 90 days after the last reply. We invite you to open a new topic if you have further questions or comments.