--- a/src/format.cpp Tue Jul 22 19:22:31 2014 +0300 +++ b/src/format.cpp Thu Jul 24 16:54:45 2014 +0300 @@ -86,7 +86,12 @@ int i = fmt[pos + ofs] - '0'; - if (i > static_cast<signed> (args.size())) +#ifdef DEBUG + if (i == 0) + formatError (fmtstr, "%0 in format string", pos); +#endif + + if (i > int (args.size())) formatError (fmtstr, String ("Format argument #") + i + " used but not defined.", pos); String replacement = args[i - 1];