RANDC and RAND variables in the same class: the second one should constraint the first one

In reply to pasciuto:
Withing the same scope if rand A and randc B gets randmoze then simulator always randomzie the all randc variable before rand variables. In addition, you can not use the solve before on randc variable. In your requirement constraint solver will fail when it tries to solve the constraint. you should review again your requirement. Havind said that you can randomize in post_randomze method by using in line constraing method.


function void post_randomize();
   std::randomize(B,A) with {B < A};
endfunction