aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorOleg Endo <olegendo@gcc.gnu.org>2019-04-29 19:20:33 +0900
committerOleg Endo <olegendo@gcc.gnu.org>2019-04-29 19:20:33 +0900
commit4f15e7f00fa2b073d6df39d4af7171f2a3f07bc9 (patch)
treea81952a90066194e5cbbf23d17cf602d83ee0f10
parente531fb203aedeb3863ebf8add0bbd8251183d27a (diff)
downloadyosys-4f15e7f00fa2b073d6df39d4af7171f2a3f07bc9.tar.gz
yosys-4f15e7f00fa2b073d6df39d4af7171f2a3f07bc9.tar.bz2
yosys-4f15e7f00fa2b073d6df39d4af7171f2a3f07bc9.zip
fix codestyle formatting
-rw-r--r--kernel/driver.cc4
-rw-r--r--kernel/yosys.cc22
-rw-r--r--kernel/yosys.h2
3 files changed, 14 insertions, 14 deletions
diff --git a/kernel/driver.cc b/kernel/driver.cc
index 8c56d059b..f273057dd 100644
--- a/kernel/driver.cc
+++ b/kernel/driver.cc
@@ -529,13 +529,13 @@ int main(int argc, char **argv)
log_error("Can't open dependencies file for writing: %s\n", strerror(errno));
bool first = true;
for (auto fn : yosys_output_files) {
- fprintf(f, "%s%s", first ? "" : " ", escape_filename_spaces (fn).c_str());
+ fprintf(f, "%s%s", first ? "" : " ", escape_filename_spaces(fn).c_str());
first = false;
}
fprintf(f, ":");
for (auto fn : yosys_input_files) {
if (yosys_output_files.count(fn) == 0)
- fprintf(f, " %s", escape_filename_spaces (fn).c_str());
+ fprintf(f, " %s", escape_filename_spaces(fn).c_str());
}
fprintf(f, "\n");
}
diff --git a/kernel/yosys.cc b/kernel/yosys.cc
index 267a7d01c..20d972150 100644
--- a/kernel/yosys.cc
+++ b/kernel/yosys.cc
@@ -482,18 +482,18 @@ void remove_directory(std::string dirname)
#endif
}
-std::string escape_filename_spaces (const std::string& filename)
+std::string escape_filename_spaces(const std::string& filename)
{
- std::string out;
- out.reserve (filename.size ());
- for (auto c : filename)
- {
- if (c == ' ')
- out += "\\ ";
- else
- out.push_back (c);
- }
- return out;
+ std::string out;
+ out.reserve(filename.size());
+ for (auto c : filename)
+ {
+ if (c == ' ')
+ out += "\\ ";
+ else
+ out.push_back(c);
+ }
+ return out;
}
int GetSize(RTLIL::Wire *wire)
diff --git a/kernel/yosys.h b/kernel/yosys.h
index d64904151..82eb069ab 100644
--- a/kernel/yosys.h
+++ b/kernel/yosys.h
@@ -257,7 +257,7 @@ std::string make_temp_dir(std::string template_str = "/tmp/yosys_XXXXXX");
bool check_file_exists(std::string filename, bool is_exec = false);
bool is_absolute_path(std::string filename);
void remove_directory(std::string dirname);
-std::string escape_filename_spaces (const std::string& filename);
+std::string escape_filename_spaces(const std::string& filename);
template<typename T> int GetSize(const T &obj) { return obj.size(); }
int GetSize(RTLIL::Wire *wire);