problem.hh: add compile-time asserts for constraints in Problem conversion.

This partially solves #26 (but I think that constraint conversions can
still be ambiguous, cf. #70).