Skip to content

Commit bf5dbac

Browse files
authored
Merge pull request #318 from jstasiak/ipcheck-drop-rust-new
ipcheck: Drop the "Rust (New)" implementation
2 parents 3877ab2 + e19d88d commit bf5dbac

File tree

8 files changed

+8
-164
lines changed

8 files changed

+8
-164
lines changed

tools/ipcheck/README.md

+5-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# IP Check
22

3-
Created for https://github.com/rust-lang/rust/pull/76098
3+
Originally created for https://github.com/rust-lang/rust/pull/76098, the tool now tests
4+
the *current* implementation of various helper methods against other programming languages.
45

56
This is a little utility program for checking the behavior of various language's IP address implementations.
67
The goal is to make sure the Rust programs are either the same or deliberately different to other languages.
@@ -11,13 +12,15 @@ This same approach might be useful for other APIs that have externally specified
1112

1213
These live under the `impls` directory.
1314

14-
- Rust (New) (`impls/rust`) with the behavior proposed in `#76098`
1515
- Rust (Current) (`impls/rust_current`) with the current behavior on `nightly`
1616
- .NET (`impls/dotnet`)
1717
- Python (`impls/python`)
1818
- Go (`impls/go`)
1919
- Java (`impls/java`)
2020

21+
There was a Rust implementation with behavior proposed in `#76098` ("Rust (New)")
22+
but the PR didn't go through so the implementation has been removed.
23+
2124
## Running
2225

2326
With the comparison languages available, you can run `cd host && cargo run` to compare them.

tools/ipcheck/host/build/build.rs

+1-2
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@ fn main() {
1212
let mut impls =
1313
std::fs::File::create("../artifacts/.impls").expect("failed to create .impls file");
1414

15-
output_impl(&mut impls, "Rust (New)", rust::build_new());
16-
output_impl(&mut impls, "Rust (Current)", rust::build_current());
15+
output_impl(&mut impls, "Rust", rust::build_current());
1716
output_impl(&mut impls, ".NET", dotnet::build());
1817
output_impl(&mut impls, "Python", python::build());
1918
output_impl(&mut impls, "Go", go::build());

tools/ipcheck/host/build/rust.rs

-4
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,5 @@
11
use std::path::Path;
22

3-
pub fn build_new() -> std::io::Result<String> {
4-
build_bin("../impls/rust_new", "../artifacts/rust_new", "ipcheck_new")
5-
}
6-
73
pub fn build_current() -> std::io::Result<String> {
84
build_bin(
95
"../impls/rust_current",

tools/ipcheck/host/main.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use serde_json::{Map, Value};
22
use std::{collections::BTreeSet, fmt::Write, io::BufRead, net::IpAddr};
33

4-
const REF_LANG: &'static str = "Rust (New)";
4+
const REF_LANG: &'static str = "Rust";
55

66
fn is_ref(lang: &str) -> bool {
77
lang.starts_with("Rust")

tools/ipcheck/impls/README.md

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,8 @@
11
Programs that accept as input a ASCII-encoded IP address to parse and run operations on. As output, these programs produce a JSON object.
22

33
## Implementations
4-
- Rust (`rust_*`) (with the behavior specified in https://github.com/rust-lang/rust/pull/76098 as `rust_new`)
4+
- Rust (`rust`)
55
- .NET (`dotnet`)
66
- Python (`python`)
77
- Go (`go`)
88
- Java (`java`)
9-

tools/ipcheck/impls/rust_new/.gitignore

-2
This file was deleted.

tools/ipcheck/impls/rust_new/Cargo.toml

-13
This file was deleted.

tools/ipcheck/impls/rust_new/main.rs

-138
This file was deleted.

0 commit comments

Comments
 (0)