private void outputMangledCharAndInfo(StringBuilder builder, int index, int depth,
			String itemName) {
		if (index >= 0) {
			if (index < mangled.length()) {
				builder.append(String.format("%04d %c ", index, mangled.charAt(index)));
			}
			else {
				builder.append(String.format("%04d   ", index));
			}
		}
		else {
			builder.append(TAB0);
		}
		if (itemName == null) {
			// Output line that looks like: "C |  |  |  |"
			while (depth-- > 0) {
				builder.append(TAB1A);
			}
			builder.append(TAB1B);
		}
		else {
			// Output line that looks like: "C +--+--+--Item"
			while (depth-- > 0) {
				builder.append(TAB2);
			}
			builder.append(itemName);
		}
		builder.append(EOL);
	}
An MDMang extension that outputs debugging parse information.
Ghidra/Features/MicrosoftDmang/src/main/java/mdemangler/MDMangParseInfo.java