We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 420f4cf commit 9dfe16fCopy full SHA for 9dfe16f
src/attributes.cpp
@@ -1162,12 +1162,12 @@ namespace attributes {
1162
for (int i = lineNumber; i<lines_.size(); i++) {
1163
std::string line;
1164
line = lines_[i];
1165
- std::string::size_type bracePos = line.find('{');
1166
- if (bracePos == std::string::npos) {
+ std::string::size_type end = line.find_first_of("{;");
+ if (end == std::string::npos) {
1167
signature.append(line);
1168
signature.push_back(' ');
1169
} else {
1170
- signature.append(line.substr(0, bracePos));
+ signature.append(line.substr(0, end));
1171
return signature;
1172
}
1173
0 commit comments