From aa40eb5dedd39263ff511de01d6833d24e33b736 Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Tue, 10 Nov 2020 14:50:38 +0100 Subject: Changing operator= and const reference in Traps --- cpp03/ex01/ScavTrap.hpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'cpp03/ex01/ScavTrap.hpp') diff --git a/cpp03/ex01/ScavTrap.hpp b/cpp03/ex01/ScavTrap.hpp index f5bc3cc..64fae68 100644 --- a/cpp03/ex01/ScavTrap.hpp +++ b/cpp03/ex01/ScavTrap.hpp @@ -6,7 +6,7 @@ /* By: charles +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2020/04/13 14:11:51 by charles #+# #+# */ -/* Updated: 2020/04/13 15:18:01 by charles ### ########.fr */ +/* Updated: 2020/11/10 14:13:16 by cacharle ### ########.fr */ /* */ /* ************************************************************************** */ @@ -21,9 +21,9 @@ class ScavTrap { public: ScavTrap(); - ScavTrap(std::string name); + ScavTrap(std::string const& name); ScavTrap(ScavTrap const& other); - void operator=(ScavTrap const& other); + ScavTrap& operator=(ScavTrap const& other); ~ScavTrap(); void rangedAttack(std::string const& target) const; -- cgit