テンプレートじゃないとダメか。
void f(bool){ ... }
template <class T> void f(T const&){ static_assert(false, "らめぇー"); }