[Python-Dev] Re: PEP 622 version 2 (Structural Pattern Matching)

2020年7月09日 13:04:23 -0700

One thing I don't understand about the PEP:
  case [x,y]:
IIUC matches any 2-element sequence.
How would you match specifically a 2-item list (say)?
Would it be
  case list([x,y]):
I would appreciate it if some kind person could enlighten me.
TIA
Rob Cliffe
_______________________________________________
Python-Dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]
https://mail.python.org/mailman3/lists/python-dev.python.org/
Message archived at 
https://mail.python.org/archives/list/[email protected]/message/NJLVOPNAZIDOCYYGJ2RJKK23ZK5FCLXT/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to