Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for parseIPSlow (0.13 sec)

  1. src/net/netip/slow_test.go

    // parseIPSlow to construct slices of specific amounts of zero fields,
    // from 1 to 8.
    var zeros = []string{"0", "0", "0", "0", "0", "0", "0", "0"}
    
    // parseIPSlow is like ParseIP, but aims for readability above
    // speed. It's the reference implementation for correctness checking
    // and against which we measure optimized parsers.
    //
    // parseIPSlow understands the following forms of IP addresses:
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Mon Mar 11 19:54:31 UTC 2024
    - 5.8K bytes
    - Viewed (0)
  2. src/net/netip/netip_test.go

    			}
    
    			// Check that the slow-but-readable parser produces the same result.
    			slow, err := parseIPSlow(test.in)
    			if err != nil {
    				t.Fatal(err)
    			}
    			if got != slow {
    				t.Errorf("ParseAddr(%q) = %#v, parseIPSlow(%q) = %#v", test.in, got, test.in, slow)
    			}
    
    			// Check that the parsed IP formats as expected.
    			s = got.String()
    			wants := test.str
    Registered: Wed Jun 12 16:32:35 UTC 2024
    - Last Modified: Tue Jun 04 17:10:01 UTC 2024
    - 54.3K bytes
    - Viewed (0)
Back to top