Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions src/odb/src/codeGenerator/templates/impl.cpp.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,9 @@ namespace odb {

bool _{{klass.name}}::operator<(const _{{klass.name}}& rhs) const
{
{% if klass.less_fields | length == 1 %}
// NOLINTBEGIN(readability-simplify-boolean-expr)
{% endif %}
{% for less in klass.less_fields %}
if ({{less.left}} >= {{less.right}}) {
return false;
Expand All @@ -42,6 +45,9 @@ namespace odb {
//User Code Begin <
//User Code End <
return true;
{% if klass.less_fields | length == 1 %}
// NOLINTEND(readability-simplify-boolean-expr)
{% endif %}
}

_{{klass.name}}::_{{klass.name}}(_dbDatabase* db)
Expand Down
2 changes: 2 additions & 0 deletions src/odb/src/db/dbChip.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -144,11 +144,13 @@ bool _dbChip::operator==(const _dbChip& rhs) const

bool _dbChip::operator<(const _dbChip& rhs) const
{
// NOLINTBEGIN(readability-simplify-boolean-expr)
if (top_ >= rhs.top_) {
return false;
}

return true;
// NOLINTEND(readability-simplify-boolean-expr)
}

_dbChip::_dbChip(_dbDatabase* db)
Expand Down
Loading