'How do I return a self argument using type annotation?
I have this "set_screen_name" method and it's returning a getter from pygame but the "get_name" method needs a self argument and anything "self" I put in won't work
def set_screen_name(self, name) -> pygame.display.set_caption(get_name()):
self.name = name
return pygame.display.set_caption(name)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
