total = F_print_write_max_d;
}
- if (write(id, string + i, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + i, total) == -1) return private_inline_f_print_to_error();
i += total;
total = 0;
f_status_t private_f_print_to_character_safely(const f_char_t character, const int id) {
if (character == 0x7f) {
- if (write(id, f_print_sequence_delete_s.string, f_print_sequence_delete_s.used) != -1) {
- return F_none;
- }
+ if (write(id, f_print_sequence_delete_s.string, f_print_sequence_delete_s.used) != -1) return F_none;
}
else if (macro_f_utf_byte_width_is(character) == 1) {
- if (write(id, f_print_sequence_unknown_s.string, f_print_sequence_unknown_s.used) != -1) {
- return F_none;
- }
+ if (write(id, f_print_sequence_unknown_s.string, f_print_sequence_unknown_s.used) != -1) return F_none;
}
else if (macro_f_utf_byte_width_is(character) > 1) {
- if (write(id, &character, 1) != -1) {
- return F_utf;
- }
+ if (write(id, &character, 1) != -1) return F_utf;
}
else if (character > 0x1f) {
- if (write(id, &character, 1) != -1) {
- return F_none;
- }
+ if (write(id, &character, 1) != -1) return F_none;
}
else {
if (write(id, f_print_sequence_set_control_s[(unsigned int) character].string, f_print_sequence_set_control_s[(unsigned int) character].used) != -1) {
}
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
if ((j >= except.used || except.array[j] != i) && string[i]) {
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
}
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
if (j >= except.used || except.array[j] != i) {
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
start = ++i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
}
else {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
start = ++i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
if (at < except_at.used && except_at.array[at] == i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (in < except_in.used && except_in.array[in].start <= i && except_in.array[in].stop >= i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (!string[i] || i + 1 == stop || total == F_print_write_max_d) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
if (at < except_at.used && except_at.array[at] == i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (in < except_in.used && except_in.array[in].start <= i && except_in.array[in].stop >= i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (i + 1 == stop || total == F_print_write_max_d) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
if (at < except_at.used && except_at.array[at] == i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (in < except_in.used && except_in.array[in].start <= i && except_in.array[in].stop >= i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
start = ++i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
if (at < except_at.used && except_at.array[at] == i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (in < except_in.used && except_in.array[in].start <= i && except_in.array[in].stop >= i) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
}
else {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
start = ++i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
total = F_print_write_max_d;
}
- if (write(id, string + i, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + i, total) == -1) return private_inline_f_print_to_error();
i += total;
total = 0;
} while (i < length && !string[i] && total < F_print_write_max_d);
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
} // for
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
i += width;
start = i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
}
else {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
if (safe.used) {
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
}
- if (write(id, safe.string, safe.used) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, safe.string, safe.used) == -1) return private_inline_f_print_to_error();
i += width;
start = i;
}
if (total + width >= F_print_write_max_d) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
total = 0;
start = i;
} // while
if (total) {
- if (write(id, string + start, total) == -1) {
- return private_inline_f_print_to_error();
- }
+ if (write(id, string + start, total) == -1) return private_inline_f_print_to_error();
}
return F_none;
#if !defined(_di_f_print_to_terminated_) || !defined(_di_f_print_to_raw_terminated_)
f_status_t private_f_print_to_terminated(const f_string_t string, const int id) {
- if (write(id, string, strlen(string)) == -1) {
- return private_inline_f_print_to_error();
- }
-
- return F_none;
+ return write(id, string, strlen(string)) == -1 ? private_inline_f_print_to_error() : F_none;
}
#endif // !defined(_di_f_print_to_terminated_) || !defined(_di_f_print_to_raw_terminated_)