+
+
+ // check if this is a positional or normal argument
+ if ( spec->m_pos > 0 )
+ {
+ // the positional arguments start from number 1 so we need
+ // to adjust the index
+ spec->m_pos--;
+ posarg_present = true;
+ }
+ else // not a positional argument...
+ {
+ spec->m_pos = nargs;
+ nonposarg_present = true;
+ }
+
+ // this conversion specifier is tied to the pos-th argument...
+ pspec[spec->m_pos] = spec;
+
+ if ( nargs++ == wxMAX_SVNPRINTF_ARGUMENTS )
+ break;
+ }
+
+
+ // warn if we lost any arguments (the program probably will crash
+ // anyhow because of stack corruption...)
+ if ( nargs == wxMAX_SVNPRINTF_ARGUMENTS )
+ {
+ wxFAIL_MSG
+ (
+ wxString::Format
+ (
+ "wxVsnprintf() currently supports only %d arguments, "
+ "but format string \"%s\" defines more of them.\n"
+ "You need to change wxMAX_SVNPRINTF_ARGUMENTS and "
+ "recompile if more are really needed.",
+ fmt, wxMAX_SVNPRINTF_ARGUMENTS
+ )
+ );