<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def rate_limit(self, rate_limit):
 """ Turn on or off rate limiting """

        self._rate_limit = bool(rate_limit)
        self._rate_limit_last_call = None
        self.clear_memoized()