Currently there's a hard-coded list of built-in type names that are highlighted specially even when the name is used as an identifier. Custom type names, on the other hand, are not highlighted.
See:

type foo = {
a: int;
b: bar;
}
let string = string_of_int