[Python-Dev] PEP 3144 review. (original) (raw)
R. David Murray rdmurray at bitdance.com
Mon Sep 28 22:47:26 CEST 2009
- Previous message: [Python-Dev] PEP 3144 review.
- Next message: [Python-Dev] PEP 3144 review.
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Mon, 28 Sep 2009 at 22:32, Antoine Pitrou wrote:
Le lundi 28 septembre 2009 à 22:11 +0200, "Martin v. Löwis" a écrit :
That's not the question that was asked, though - the question asked was "Under what circumstances would I want to specify...". I hope most people agree that it is desirable to be able to specify a network not just by its network address. To me it makes no sense to "specify a network not just by its network address", because by definition a prefix + mask is all that characterizes a network: that's all you need to specify it entirely. Adding a "base address" would be like adding a "port number" attribute to the Address class: it's abusing an existing class by adding irrelevant information. I may be mistaken, but it seems to me that, in the IP world, nowhere does such a "network + host" hybrid appear. You find networks (prefix + mask) in routing protocols, and host addresses in applicative protocols.
You do find "address plus mask" when specifying an IP address for an interface. This is a shorthand for specifying the IP address plus the network, since the network can be derived from the IP plus the mask. But it is a shorthand, it isn't an entity in its own right. There is no such thing as "a network that has an IP", there is only an interface configuration that has an IP and an associated network.
--David
- Previous message: [Python-Dev] PEP 3144 review.
- Next message: [Python-Dev] PEP 3144 review.
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]