private void endOfOperandFormatBlockErrorCheck() throws AssemblerException {

		// Error checking after all lines of an operandFormat declaration have been read
		
		ArrayList<String> instructionFormat = currentMnemFormat.getInstructionFormat();
		int totalBits = 0;

		for (String instruction : instructionFormat) {
			InstructionFormat insFormat = data.getInstructionFormatHash().get(instruction);

			if (insFormat == null) {
				abortMnem = true;
				throw new AssemblerException(
						currentMnemFormat.getRawLinesString()
								+ "\nMnemonicData error: Instruction \""
								+ instruction
								+ "\" not defined in instructionFormat section.");
			}

			ArrayList<String> instructions = insFormat.getFields();

			for (String field : instructions) {
				int bits = insFormat.getFieldBitHash().get(field);
				totalBits += bits;

				// Field defined in global encodings
				if (currentMnemonic.getGlobalFieldEncodingHash().get(field) != null) {
					String field1 = currentMnemonic.getGlobalFieldEncodingHash().get(field);					
					int noOfBits = field1.length();

					if (noOfBits > bits) {
						abortMnem = true;
						throw new AssemblerException(
								currentMnemonic.getRawLinesString()
										+ "\nMnemonicData error: Encoding for field \""
										+ field
										+ "\" in \""
										+ currentMnemonic.getMnemonic()
										+ "\" global encodings ("
										+ currentMnemonic.getRawGlobalFieldEncodingString()
										+ ")\nexceeds expected " 
										+ bits
										+ " bits in instruction format \""
										+ instruction + "\" ("
										+ insFormat.getRawLineString() 
										+ ").");
					}
				}

				// Field defined in local encodings
				else if (currentMnemFormat.getFieldBitHash().get(field) != null) {
					String field1 = currentMnemFormat.getFieldBitHash().get(field);
					int noOfBits = field1.length();
					
					if (noOfBits > bits) {
						abortMnem = true;
						throw new AssemblerException(
								currentMnemFormat.getRawLinesString()
										+ "\nMnemonicData error: Encoding for field \""
										+ field 
										+ "\" in local encodings for \""
										+ currentMnemonic.getMnemonic()
										+ "\" format \""
										+ currentMnemFormat.getMnemFormat()
										+ "\"\nexceeds expected " 
										+ bits
										+ " bits in instruction format \""
										+ instruction + "\" ("
										+ insFormat.getRawLineString() 
										+ ").");
					}
				}

				// Field defined in operand encodings
				else if (existsInOperandFieldEncodings(currentMnemFormat.getOperandFieldEncodings(), field));

				else {
					abortMnem = true;
					throw new AssemblerException(currentMnemonic.getRawLinesString()
							+ "\nMnemonicData error: Field \"" 
							+ field
							+ "\" in instruction format \"" 
							+ instruction
							+ "\" (" + insFormat.getRawLineString()
							+ ")\nnot found within global \""
							+ currentMnemonic.getMnemonic()
							+ "\" encodings ("
							+ currentMnemonic.getRawGlobalFieldEncodingString()
							+ ") or in \"" 
							+ currentMnemonic.getMnemonic()
							+ "\" format \""
							+ currentMnemFormat.getMnemFormat() 
							+ "\".");
				}
			}
		}
		
		int minAdrUnit = data.getMinAdrUnit();

		// If total instruction size is not divisible by minimum addressable unit
		if (totalBits % minAdrUnit != 0)
			throw new AssemblerException(currentMnemFormat.getRawLinesString()
					+ "\nMnemonicData error: Total instruction size ("
							+ totalBits
							+ " bits) should be divisable by the minimum addressable unit ("
							+ minAdrUnit + ")");
	}