thytype_abbrev : {Name:string,Thy:string} * hol_type * bool -> unit
If there was an existing abbreviation for t$n, then this will be replaced by the call.
In addition, after the given call, this abbreviation will become the preferred binding for the bare name n. Other abbreviations in different theories will need to use the form with fully-qualified names (thy1$n, thy2$n etc).
If the boolean flag is false, this invocation is comparable to the behaviour after intputonly_type_abbrev: the abbreviation can be used to input types of the desired pattern, but such types will print as they did previously.
It is legitimate to use a string for the theory component of the record that does not correspond to the current theory. Indeed, it is perfectly reasonable to do this, if one wants to give priority to a particular ancestral abbreviation.