private ArrayList<String> compileAssignment(String varname, String value) throws MCCAssignmentException {
		if (!vars.containsKey(varname)) throw new MCCAssignmentException();
		ArrayList<String> out = new ArrayList<String>();
		Variable targetVar = vars.get(varname);
		boolean byVar = false;
		if (value == "false" || value == "true") {
			if (!targetVar.isOfType("boolean")) throw new MCCAssignmentException();
		} else if (value.matches("^" + REGEX_NUMBER + "$")) {
			if (targetVar.isOfType("boolean")) throw new MCCAssignmentException();
		} else {
			if (!vars.containsKey(value)) throw new MCCAssignmentException();
			byVar = true;
		}
		if (byVar) {
			Variable sourceVar = vars.get(value);
			if (Variable.loadedAddress != sourceVar.address) out.add("read " + REGISTER_VAR + " " + vars.get(value).address);
		} else {
			out.add("movi " + REGISTER_VAR + " " + value);
		}
		out.add("save " + REGISTER_VAR + " " + targetVar.address);
		Variable.loadedAddress = targetVar.address;
		System.out.println("assigned " + value + " to " + varname);
		return out;
	}