A branded string is a string that has a unique type, so that it can be
distinguished from other strings. This is useful when you want to ensure
that a string is only used in a specific context. When assigning to a
branded string type it's not allowed to assign a non-branded string, or a
string of the wrong brand:
A branded string is a string that has a unique type, so that it can be distinguished from other strings. This is useful when you want to ensure that a string is only used in a specific context. When assigning to a branded string type it's not allowed to assign a non-branded string, or a string of the wrong brand: