private void encodeFunctionDefinition(Encoder encoder, FunctionDefinition type)
			throws IOException {
		encoder.openElement(ELEM_TYPE);
		encodeNameIdAttributes(encoder, type);
		encoder.writeString(ATTRIB_METATYPE, "code");
		encoder.writeSignedInteger(ATTRIB_SIZE, 1);		// Force size of 1
		CompilerSpec cspec = program.getCompilerSpec();
		FunctionPrototype fproto = new FunctionPrototype(type, cspec, voidInputIsVarargs);
		fproto.encodePrototype(encoder, this, -1);
		encoder.closeElement(ELEM_TYPE);
	}
Encode a FunctionDefinition data-type to the stream.
@param encoder is the stream encoder
@param type is the FunctionDefinition data-type
@throws IOException for errors in the underlying stream
Ghidra/Framework/SoftwareModeling/src/main/java/ghidra/program/model/pcode/PcodeDataTypeManager.java