Skip to content
Merged
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
5 changes: 2 additions & 3 deletions cpp2rust/converter/converter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2354,7 +2354,6 @@ bool Converter::ConvertIncAndDec(clang::UnaryOperator *expr) {
default:
return false;
}
std::unreachable();
}

bool Converter::VisitUnaryOperator(clang::UnaryOperator *expr) {
Expand Down Expand Up @@ -2814,7 +2813,7 @@ bool Converter::VisitInitListExpr(clang::InitListExpr *expr) {
if (auto arr_ty = ctx_.getAsConstantArrayType(expr->getType())) {
assert(
(arr_ty->getSize().getZExtValue() - expr->getNumInits()) &&
"Number of initializers should be less that total size of array");
"Number of initializers should be less than total size of array");
for (unsigned i = 0;
i < arr_ty->getSize().getZExtValue() - expr->getNumInits(); ++i) {
ConvertVarInit(expr->getArrayFiller()->getType(),
Expand Down Expand Up @@ -3002,7 +3001,7 @@ bool Converter::VisitCXXConstructExpr(clang::CXXConstructExpr *expr) {
if (ctor->isCopyOrMoveConstructor() ||
(ctor->isConvertingConstructor(false) && ctor->getNumParams() == 1 &&
ctor->getParamDecl(0)->getType()->isRValueReferenceType())) {
// Take supress before recursing into the child.
// Take suppress before recursing into the child.
bool suppress = PushSuppressIteratorClone::take(*this);
Convert(expr->getArg(0));
if (ctor->isCopyConstructor() && !suppress) {
Expand Down
Loading