Ignore:
Timestamp:
Oct 22, 2007, 8:17:05 PM (14 years ago)
Author:
Peter
Message:

no comma in help output in case of short flag but no long flag

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/yat/utility/Option.cc

    r980 r986  
    101101  std::string Option::print1(void) const
    102102  {
    103     if (short_name())
    104       return std::string("-")+short_name()+std::string(",");
    105     return std::string("   ");
     103    std::string str;
     104    if (short_name()){
     105      str = std::string("-")+short_name();
     106      if (!long_name().empty())
     107        str += std::string(",");
     108    }
     109    else
     110      str = std::string("   ");
     111    return str;
    106112  }
    107113
Note: See TracChangeset for help on using the changeset viewer.