{"action":"created","issue":{"url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/16","labels_url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/16/labels{/name}","comments_url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/16/comments","events_url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/16/events","html_url":"https://github.com/chriskohlhoff/asio-tr2/issues/16","id":57712968,"number":16,"title":"Reconsider ip::address default constructor","user":{"login":"chriskohlhoff","id":462538,"avatar_url":"https://avatars.githubusercontent.com/u/462538?v=3","gravatar_id":"","url":"https://api.github.com/users/chriskohlhoff","html_url":"https://github.com/chriskohlhoff","followers_url":"https://api.github.com/users/chriskohlhoff/followers","following_url":"https://api.github.com/users/chriskohlhoff/following{/other_user}","gists_url":"https://api.github.com/users/chriskohlhoff/gists{/gist_id}","starred_url":"https://api.github.com/users/chriskohlhoff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chriskohlhoff/subscriptions","organizations_url":"https://api.github.com/users/chriskohlhoff/orgs","repos_url":"https://api.github.com/users/chriskohlhoff/repos","events_url":"https://api.github.com/users/chriskohlhoff/events{/privacy}","received_events_url":"https://api.github.com/users/chriskohlhoff/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/labels/applied-to-draft","name":"applied-to-draft","color":"fef2c0"},{"url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/labels/design","name":"design","color":"fad8c7"},{"url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/labels/internet","name":"internet","color":"006b75"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":9,"created_at":"2015-02-15T01:00:52Z","updated_at":"2015-05-05T08:48:38Z","closed_at":null,"body":"The proposal currently specifies that a default constructed `ip::address` have `is_ipv4() == false` and `is_ipv6() == false`. Or to put it another way, the `ip::address` class can contain:\r\n\r\n* an IPv4 address; or\r\n* an IPv6 address; or\r\n* a Not-An-Address value\r\n\r\nSo right now the `ip::address` class can represent a value that is outside the domain of valid IP addresses. This is not the established practice in Asio and as I implement this I am finding that it *might* cause inconsistencies in the other types that use `ip::address`, like `ip::basic_endpoint`.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/comments/98997996","html_url":"https://github.com/chriskohlhoff/asio-tr2/issues/16#issuecomment-98997996","issue_url":"https://api.github.com/repos/chriskohlhoff/asio-tr2/issues/16","id":98997996,"user":{"login":"chriskohlhoff","id":462538,"avatar_url":"https://avatars.githubusercontent.com/u/462538?v=3","gravatar_id":"","url":"https://api.github.com/users/chriskohlhoff","html_url":"https://github.com/chriskohlhoff","followers_url":"https://api.github.com/users/chriskohlhoff/followers","following_url":"https://api.github.com/users/chriskohlhoff/following{/other_user}","gists_url":"https://api.github.com/users/chriskohlhoff/gists{/gist_id}","starred_url":"https://api.github.com/users/chriskohlhoff/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chriskohlhoff/subscriptions","organizations_url":"https://api.github.com/users/chriskohlhoff/orgs","repos_url":"https://api.github.com/users/chriskohlhoff/repos","events_url":"https://api.github.com/users/chriskohlhoff/events{/privacy}","received_events_url":"https://api.github.com/users/chriskohlhoff/received_events","type":"User","site_admin":false},"created_at":"2015-05-05T08:48:38Z","updated_at":"2015-05-05T08:48:38Z","body":"## Pre-Lenexa Summary\r\n\r\n[\\[internet.address\\]](http://open-std.org/JTC1/SC22/WG21/docs/papers/2015/n4478.html#internet.address)\r\n\r\nThe original asio design of `ip::address` was that an address is either IPv4 or IPv6. A default constructed address is the IPv4 `any` address.\r\n\r\nDuring SG4 discussion of the separate IP Address proposal, the design was changed to introduce a not-an-address value as the default. As described above, adding this out-of-domain value caused some consistency problems when incorporated into the wider Asio-based proposal, e.g. in the `basic_endpoint` default constructor. It also significantly complicated the specification of some functions, like the `ip::address` relational operators.\r\n\r\nWhen we discussed about this in Cologne, we decided that we should return to Asio's original behaviour. LEWG needs to confirm this decision.\r\n\r\nThe change was included in revision 5. An implementation can be found on the master branch of Asio's [GitHub repository](https://github.com/chriskohlhoff/asio)."}}