Skip to content

Commit

Permalink
Remove unused comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Samuel Herts committed Sep 16, 2024
1 parent 8c842a2 commit d929315
Showing 1 changed file with 0 additions and 34 deletions.
34 changes: 0 additions & 34 deletions bigint.h
Original file line number Diff line number Diff line change
Expand Up @@ -145,16 +145,6 @@ namespace BigInt {
bigint operator+=(const bigint &rhs)
{
*this = add(*this, rhs);

// else if (rhs.base_repr > 0 && this->base_repr > std::numeric_limits<long long>::max() - rhs.base_repr ||
// rhs < 0 && this->base_repr < std::numeric_limits<long long>::min() - rhs.base_repr)
// {
// *this = add(std::to_string(this->base_repr), std::to_string(rhs.base_repr));
// }
// else
// {
// this->base_repr += rhs.base_repr;
// }
return *this;
}

Expand All @@ -169,16 +159,6 @@ namespace BigInt {
{

*this = subtract(*this, rhs);

// else if ((rhs.base_repr < 0 && this->base_repr > std::numeric_limits<long long>::max() + rhs.base_repr) ||
// (rhs > 0 && this->base_repr < std::numeric_limits<long long>::min() + rhs.base_repr))
// {
// *this = subtract(std::to_string(this->base_repr), std::to_string(rhs.base_repr));
// }
// else
// {
// this->base_repr -= rhs.base_repr;
// }
return *this;
}

Expand All @@ -192,20 +172,6 @@ namespace BigInt {
bigint operator*=(const bigint &rhs)
{
*this = multiply(*this, rhs);

// else if ((this->base_repr == -1 && rhs.base_repr == std::numeric_limits<long long>::min()) ||
// (rhs.base_repr == -1 && this->base_repr == std::numeric_limits<long long>::min()) ||
// (rhs.base_repr != 0 &&
// this->base_repr > std::numeric_limits<long long>::max() / rhs.base_repr) ||
// (rhs.base_repr != 0 &&
// this->base_repr < std::numeric_limits<long long>::min() / rhs.base_repr))
// {
// *this = multiply(std::to_string(this->base_repr), std::to_string(rhs.base_repr));
// }
// else
// {
// this->base_repr *= rhs.base_repr;
// }
return *this;
}

Expand Down

0 comments on commit d929315

Please sign in to comment.