static CompilerSpec getProgramCompilerSpec(Program program, CompilerSpec langSpec) {
		if (langSpec instanceof ProgramCompilerSpec) {
			throw new IllegalArgumentException(
				"Cannot instantiate ProgramCompilerSpec from another ProgramCompilerSpec");
		}
		if (langSpec instanceof BasicCompilerSpec) {
			return new ProgramCompilerSpec(program, (BasicCompilerSpec) langSpec);
		}
		return langSpec;
	}
Transition specified compiler specification langSpec into a program-specific one which
supports extensions. If the specified langSpec is not a {@link BasicCompilerSpec} instance,
the langSpec argument will be returned unmodified.

@param program program to which langSpec applies
@param langSpec initial compiler specification which does not support extensions.
@return compiler specification to be used with program
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/database/ProgramCompilerSpec.java