We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b7dc83a commit 7cabaa6Copy full SHA for 7cabaa6
src/libstd/net/addr.rs
@@ -1268,5 +1268,10 @@ mod tests {
1268
assert!(v6_1 < v6_3);
1269
assert!(v4_3 > v4_1);
1270
assert!(v6_3 > v6_1);
1271
+
1272
+ // compare with an inferred right-hand side
1273
+ assert_eq!(v4_1, "224.120.45.1:23456".parse().unwrap());
1274
+ assert_eq!(v6_1, "[2001:db8:f00::1002]:23456".parse().unwrap());
1275
+ assert_eq!(SocketAddr::V4(v4_1), "224.120.45.1:23456".parse().unwrap());
1276
}
1277
0 commit comments