public static String getAnonNameForMeFromParentContext(DIEAggregate diea) {
		DebugInfoEntry parent = diea.getHeadFragment().getParent();
		if (parent == null) {
			return null;
		}

		DWARFProgram prog = diea.getProgram();
		int typeDefCount = 0;
		for (DebugInfoEntry childDIE : parent.getChildren()) {
			DIEAggregate childDIEA = prog.getAggregate(childDIE);
			if (diea == childDIEA || diea.getOffset() == childDIEA.getOffset()) {
				return "anon_%s_%d".formatted(childDIEA.getTag().getContainerTypeName(),
					typeDefCount);
			}
			if (childDIEA.getTag().isNamedType()) {
				typeDefCount++;
			}
		}
		throw new RuntimeException("Could not find child in parent's list of children: child:\n" +
			diea + ",\nparent:\n" + parent);
	}
Creates a name for anon types based on their position in their parent's childList.

@param diea the die aggregate.
@return the anonymous name of the die aggregate.
Ghidra/Features/Base/src/main/java/ghidra/app/util/bin/format/dwarf/DWARFUtil.java