From: Lukas Jiriste Date: Thu, 24 Oct 2024 13:14:03 +0000 (+0200) Subject: Remove the constructor/destructor messages in ex03 X-Git-Url: https://git.ljiriste.work/?a=commitdiff_plain;h=a04f480c44082c1c804ca3452895761100e793ea;p=42%2FCPP_Module_02 Remove the constructor/destructor messages in ex03 --- diff --git a/ex03/Fixed.cpp b/ex03/Fixed.cpp index 1d6acbe..362baa1 100644 --- a/ex03/Fixed.cpp +++ b/ex03/Fixed.cpp @@ -4,32 +4,26 @@ Fixed::Fixed(): m_num(0) { - std::cout << "Default constructor called\n"; } Fixed::Fixed(const int init): m_num(init << point_pos) { - std::cout << "Int constructor called\n"; } Fixed::Fixed(const float init): m_num(roundf(init * (1 << point_pos))) { - std::cout << "Float constructor called\n"; } Fixed::Fixed(const Fixed &other) { - std::cout << "Copy constructor called\n"; *this = other; } Fixed::~Fixed() { - std::cout << "Destructor called\n"; } Fixed &Fixed::operator=(const Fixed &other) { - std::cout << "Copy assignment operator called\n"; if (this == &other) return (*this); m_num = other.getRawBits();