Python Forum
what means in Python the "->"?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
what means in Python the "->"?
#1
Here the code section in Python :

https://refactoring.guru/design-patterns...on/example

uses "->" like in a function declaration... what is mean ... is method ??? Is it Python 3? the -> isn't for PHP OOP usage, what means in Python the "->"?
Reply
#2
This is for static type checker mypy.
I'm not 'in'-sane. Indeed, I am so far 'out' of sane that you appear a tiny blip on the distant coast of sanity. Bucky Katt, Get Fuzzy

Da Bishop: There's a dead bishop on the landing. I don't know who keeps bringing them in here. ....but society is to blame.
Reply
#3
It helps your IDE to warn you about wrong types.
       
Almost dead, but too lazy to die: https://sourceserver.info
All humans together. We don't need politicians!
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Understand what it means that everything in Python is an object... bytecrunch 8 3,716 Mar-19-2021, 04:47 PM
Last Post: nilamo
  what "return" means? PY_beginner 9 3,840 Oct-10-2019, 07:18 AM
Last Post: newbieAuggie2019
  effective means to flip boolean values? Exsul 3 4,309 Aug-25-2019, 03:58 PM
Last Post: Exsul
  Smtplib: What does context argument means? Pythenx 1 3,049 Mar-27-2019, 06:25 PM
Last Post: nilamo
  what from .something means sylas 1 2,568 May-17-2018, 06:19 AM
Last Post: buran

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020