| 9323 | |
| 9324 | auto name() const -> std::string { return *m_name; } |
| 9325 | auto set( std::string const& newName ) -> ParserResult { |
| 9326 | |
| 9327 | auto lastSlash = newName.find_last_of( "\\/" ); |
| 9328 | auto filename = ( lastSlash == std::string::npos ) |
| 9329 | ? newName |
| 9330 | : newName.substr( lastSlash+1 ); |
| 9331 | |
| 9332 | *m_name = filename; |
| 9333 | if( m_ref ) |
| 9334 | return m_ref->setValue( filename ); |
| 9335 | else |
| 9336 | return ParserResult::ok( ParseResultType::Matched ); |
| 9337 | } |
| 9338 | }; |
| 9339 | |
| 9340 | class Arg : public ParserRefImpl<Arg> { |
no test coverage detected