diff options
| author | Dominik Kaiser | 2025-02-13 13:18:56 +0100 |
|---|---|---|
| committer | Dominik Kaiser | 2025-02-13 13:18:56 +0100 |
| commit | 80234b81fd22f737d3c86f5993745b1c7053a56a (patch) | |
| tree | 7841a9d8c9c8caaf5f2ce289f1e0949ed40cbca1 /ex00/Fixed.hpp | |
| parent | 9aeae0c6e3d453cab20c0279747d6cb804d49a91 (diff) | |
| download | cpp02-80234b81fd22f737d3c86f5993745b1c7053a56a.tar.gz cpp02-80234b81fd22f737d3c86f5993745b1c7053a56a.zip | |
Implement Fixed class
Diffstat (limited to 'ex00/Fixed.hpp')
| -rw-r--r-- | ex00/Fixed.hpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/ex00/Fixed.hpp b/ex00/Fixed.hpp index 114905d..89ccfe5 100644 --- a/ex00/Fixed.hpp +++ b/ex00/Fixed.hpp @@ -6,26 +6,26 @@ /* By: dkaiser <dkaiser@student.42heilbronn.de +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/02/12 17:05:34 by dkaiser #+# #+# */ -/* Updated: 2025/02/13 12:50:05 by dkaiser ### ########.fr */ +/* Updated: 2025/02/13 13:06:51 by dkaiser ### ########.fr */ /* */ /* ************************************************************************** */ #ifndef FIXED_H_ #define FIXED_H_ -class Fixed -{ - public: - Fixed(void); - Fixed(const Fixed &other); - Fixed &operator=(const Fixed &other); - ~Fixed(void); +class Fixed { + public: + Fixed(void); + Fixed(const Fixed &other); + Fixed &operator=(const Fixed &other); + ~Fixed(void); - int getRawBits(void) const; - void setRawBits(int const raw); - private: - static const int fractional_bits = 8; - int value; -} + int getRawBits(void) const; + void setRawBits(int const raw); + + private: + static const int fractional_bits = 8; + int raw_value; +}; #endif |
