Martin v. Löwis <martin <at> v.loewis.de> writes:
> 
> Still, people proposing that 192.168.1.1/24 should be rejected (I still
> don't know whether anybody is actually proposing that) *have* to provide
> a proposal how this should be input instead.

It was proposed to have a dedicated function or class method which would parse
such strings and return a (Network, Address) tuple corresponding to the two
objects that are described by that single notation.

  >>> parse_network_and_host('192.168.1.1/24')
  (Network('192.168.1.0/24'), Address('192.168.1.1'))


Regards

Antoine.


_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to