Must constraint for the ipv6 address

we have a scenario as follows.

leaf a {
string;
}
leaf b{
type inet:ip-address
}

If the user enters ipv6 address , then need to check leaf a for a particular value. Can you please suggest what can be done here in the must.

Thanks
Phani

I thunk must statement expression should check if value is IPV4 or specific IPV6 values. It depends on allowed IPV6 values, if regex pattern can be easily made. If not, you may consider to use validation point.