Can I combine hard constraint and dist constraint?

In reply to dave_59:

Sorry, you’re right, of course.
Very simple:

int field;
constraint hard_vals{
field inside {0,256,512,1024};
}
constraint weights{
soft field dist { 0:=2,256:=4,512:=1,1024:=3};
}

Does constraint hard_vals enforce a uniform distribution or, barring any other constraints, will the weights constraint be enforced?

Thanks