- wxASSERT_MSG( !shrt.empty() || !lng.empty(),
- _T("option should have at least one name") );
-
- wxASSERT_MSG
- (
- GetShortOptionName(shrt.begin(), shrt.end()).Len() == shrt.Len(),
- wxT("Short option contains invalid characters")
- );
-
- wxASSERT_MSG
- (
- GetLongOptionName(lng.begin(), lng.end()).Len() == lng.Len(),
- wxT("Long option contains invalid characters")
- );
-
+ // wxCMD_LINE_USAGE_TEXT uses only description, shortName and longName is empty
+ if ( k != wxCMD_LINE_USAGE_TEXT )
+ {
+ wxASSERT_MSG
+ (
+ !shrt.empty() || !lng.empty(),
+ wxT("option should have at least one name")
+ );
+
+ wxASSERT_MSG
+ (
+ GetShortOptionName(shrt.begin(), shrt.end()).Len() == shrt.Len(),
+ wxT("Short option contains invalid characters")
+ );
+
+ wxASSERT_MSG
+ (
+ GetLongOptionName(lng.begin(), lng.end()).Len() == lng.Len(),
+ wxT("Long option contains invalid characters")
+ );
+ }