private void addPrimaryEquate() throws DuplicateNameException, InvalidInputException {
		EquateTable equateTable = program.getEquateTable();
		Equate equate = equateTable.getEquate(convertName);

		if (equate != null && equate.getValue() != equateValue) {
			String msg = "Equate named " + convertName + " already exists with value of " +
				equate.getValue() + ".";
			throw new DuplicateNameException(msg);
		}

		if (equate == null) {
			equate = equateTable.createEquate(convertName, equateValue);
		}

		// Add reference to existing equate
		if (convertHash != 0) {
			equate.addReference(convertHash, convertAddress);
		}
		else {
			equate.addReference(convertAddress, convertIndex);
		}
	}
Add equate based on the alternate constant information: altAddress, altName, altIndex
@throws DuplicateNameException if there is already an equate with same name but different value
@throws InvalidInputException if the equate name is illegal
Ghidra/Features/Decompiler/src/main/java/ghidra/app/plugin/core/decompile/actions/ConvertConstantTask.java