private void createAutoCommentFromReference(Set<String> results, Program program,
			Reference reference) {

		Address toAddress = reference.getToAddress();
		if (createFunctionCallPreview(results, reference, program, toAddress)) {
			return;
		}

		Data data = getData(program, toAddress);
		if (data == null) {
			return; // nothing there
		}

		if (createIndirectDataReferencePreview(results, reference, program, toAddress, data)) {
			return;
		}

		handleDirectDataReferencePreview(results, toAddress, data);
	}
Returns the number of comments that can be added before reaching the maximum number of
comments
@return the number of comments
Ghidra/Features/Base/src/main/java/ghidra/app/util/EolComments.java