private static void renameDataType(DataTypeManager sourceDTM, DataType sourceDT,
			DataType dtToCopy) {
		if (isAutoNamedTypedef(dtToCopy)) {
			if (sourceDT instanceof TypeDef) {
				((TypeDef) sourceDT).enableAutoNaming();
				return;
			}
		}
		String name = dtToCopy.getName();
		CategoryPath path = sourceDT.getCategoryPath();
		if (sourceDTM.getDataType(path, name) != null) {
			name = ((DataTypeManagerDB) sourceDTM).getUnusedConflictName(sourceDT.getCategoryPath(),
				dtToCopy);
		}
		try {
			sourceDT.setName(name);
		}
		catch (InvalidNameException e) {
			throw new AssertException(
				"This should not occur here, all we did is tack more on the end");
		}
		catch (DuplicateNameException e) {
			throw new AssertException(
				"This should not occur here, we already looked to see if it existed");
		}
	}
If the indicated data type is associated with a source archive, this will remove the
association.
@param dataType the data type to be disassociated from a source archive.
Ghidra/Features/Base/src/main/java/ghidra/app/plugin/core/datamgr/DataTypeSynchronizer.java