Michel Albert added the comment:

I second "supernet_of" and "subnet_of". I'll implement it as soon as I get 
around it.

I have been thinking about using ``in`` and ``<=`` and, while I initially liked 
the idea for tests, I find both operators too ambiguous.

With ``in`` there's the already mentioned ambiguity of containment/inclusion. 
And ``<=`` could mean is a smaller size (has less individual hosts), but could 
also mean that it is a subnet, or even that it is "located to the left".

Naming it ``subnet_of`` makes it 100% clear what it does.

Currently, ``a <= b`` returns ``True`` if a comes before/lies on the left of b.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue20825>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to