Moved domain filtering code from VariableCompiler to ConstraintCompiler as it
can be also useful there