| 50 | } |
| 51 | |
| 52 | std::string ValidateOptionLang( const std::string& lang ) |
| 53 | { |
| 54 | if( IsNumber( lang ) == false ) { |
| 55 | return kInvalidArgument; |
| 56 | } |
| 57 | |
| 58 | try { |
| 59 | std::ignore = std::stoi( lang ); |
| 60 | } |
| 61 | catch( const std::exception& e ) { |
| 62 | return e.what(); |
| 63 | } |
| 64 | |
| 65 | return {}; |
| 66 | } |
| 67 | |
| 68 | } // namespace rcedit |