non-member function ‘xxxx’ cannot have cv-qualifier Methods that do not belong to any class are modified with const solution: remove const