Add attributes to `std.socket`

`std.socket` now has `@safe` public API.

Also added few fixes.
It's a refactoring to correspond *everythng should be `const` except it can't* rule.