f_return_status f_print_string(FILE *output, const f_string string, const f_string_length length) {
#ifndef _di_level_0_parameter_checking_
if (string == 0) return F_status_set_error(F_parameter);
- if (length < 1) return F_status_set_error(F_parameter);
#endif // _di_level_0_parameter_checking_
+ if (length == 0) return F_data_not;
+
register f_string_length i = 0;
for (; i < length; i++) {
#ifndef _di_f_print_string_dynamic_
f_return_status f_print_string_dynamic(FILE *output, const f_string_static buffer) {
- #ifndef _di_level_0_parameter_checking_
- if (buffer.used == 0) return F_status_set_error(F_parameter);
- #endif // _di_level_0_parameter_checking_
+ if (buffer.used == 0) return F_data_not;
register f_string_length i = 0;
#ifndef _di_level_0_parameter_checking_
if (range.start < 0) return F_status_set_error(F_parameter);
if (range.start > range.stop) return F_status_set_error(F_parameter);
- if (buffer.used == 0) return F_status_set_error(F_parameter);
if (range.start >= buffer.used) return F_status_set_error(F_parameter);
if (range.stop >= buffer.used) return F_status_set_error(F_parameter);
#endif // _di_level_0_parameter_checking_
+ if (buffer.used == 0) return F_data_not;
+
register f_string_length i = range.start;
for (; i <= range.stop; i++) {
*
* @return
* F_none on success.
+ * F_data_not if length is 0.
* F_output (with error bit) on failure.
* F_parameter (with error bit) if a parameter is invalid.
*/
*
* @return
* F_none on success.
+ * F_data_not if buffer.used is 0.
* F_output (with error bit) on failure.
* F_parameter (with error bit) if a parameter is invalid.
*/
*
* @return
* F_none on success.
+ * F_data_not if buffer.used is 0.
* F_output (with error bit) on failure.
* F_parameter (with error bit) if a parameter is invalid.
*/