kernel/rtlil: Trailing whitespace cleanup

This commit is contained in:
dragonmux 2023-07-26 20:50:55 +01:00
parent b59c717245
commit ef7e358576
No known key found for this signature in database
GPG Key ID: 64861EA89B35507A
1 changed files with 3 additions and 3 deletions

View File

@ -443,13 +443,13 @@ namespace RTLIL
static inline std::string encode_filename(const std::string &filename)
{
std::stringstream val;
if (!std::any_of(filename.begin(), filename.end(), [](char c) {
return static_cast<unsigned char>(c) < 33 || static_cast<unsigned char>(c) > 126;
if (!std::any_of(filename.begin(), filename.end(), [](char c) {
return static_cast<unsigned char>(c) < 33 || static_cast<unsigned char>(c) > 126;
})) return filename;
for (unsigned char const c : filename) {
if (c < 33 || c > 126)
val << stringf("$%02x", c);
else
else
val << c;
}
return val.str();