"...assets/git@developer.sourcefind.cn:wangsen/mineru.git" did not exist on "d0558abb43844102ba4e7d7b56c7953531b33d67"
Commit 673e8ff2 authored by Paul's avatar Paul
Browse files

Formatting

parent 3d4d0179
...@@ -24,15 +24,14 @@ template <class T> ...@@ -24,15 +24,14 @@ template <class T>
std::string compute_command_name() std::string compute_command_name()
{ {
static const std::string& tname = get_type_name<T>(); static const std::string& tname = get_type_name<T>();
auto name = tname.substr(tname.rfind("::") + 2); auto name = tname.substr(tname.rfind("::") + 2);
if (ends_with(name, "_command")) if(ends_with(name, "_command"))
name = name.substr(0, name.size()-8); name = name.substr(0, name.size() - 8);
if (ends_with(name, "_cmd")) if(ends_with(name, "_cmd"))
name = name.substr(0, name.size()-4); name = name.substr(0, name.size() - 4);
return name; return name;
} }
template <class T> template <class T>
const std::string& command_name() const std::string& command_name()
{ {
......
...@@ -125,10 +125,7 @@ struct verify : command<verify> ...@@ -125,10 +125,7 @@ struct verify : command<verify>
struct compile : command<compile> struct compile : command<compile>
{ {
compiler c; compiler c;
void parse(argument_parser& ap) void parse(argument_parser& ap) { c.parse(ap); }
{
c.parse(ap);
}
void run() void run()
{ {
...@@ -141,10 +138,7 @@ struct compile : command<compile> ...@@ -141,10 +138,7 @@ struct compile : command<compile>
struct run_cmd : command<run_cmd> struct run_cmd : command<run_cmd>
{ {
compiler c; compiler c;
void parse(argument_parser& ap) void parse(argument_parser& ap) { c.parse(ap); }
{
c.parse(ap);
}
void run() void run()
{ {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment