use "static if" syntax for assertion requirements
Contract Programming Library for C++
Status: Pre-Alpha
Brought to you by:
lcaminiti
Following N3329 "static if" proposal, replace assertion requirement syntax:
postcondition( back() == value, requires boost::has_eqaul<T>::value )
with a static if:
postcondition( static if(boost::has_equal<T>::value) ( back() == value ) // optional else ( ... ) )
Note that D already supports "static if" so it essentially already supports assertion requirements (even if maybe not actually documented for D's contracts).