1. 09 Sep, 2016 7 commits
  2. 08 Sep, 2016 30 commits
  3. 07 Sep, 2016 3 commits
    • Chris Broadfoot's avatar
      doc: document go1.7.1 · 9e040979
      Chris Broadfoot authored
      Change-Id: I4dc1ff7bfc67351a046f199dee8b7a9eadb1e524
      Reviewed-on: https://go-review.googlesource.com/28693Reviewed-by: 's avatarBrad Fitzpatrick <bradfitz@golang.org>
      9e040979
    • Joe Tsai's avatar
      net: remove parsing of negative decimals in IPv4 literal · 3ef0e8f8
      Joe Tsai authored
      https://golang.org/cl/27206 fixed the dtoi function such that
      it now properly parses negative number. Ironically, this causes
      several other functions that depended on dtoi to now (incorrectly)
      parse negative numbers.
      
      For example, ParseCIDR("-1.0.0.0/32") used to be rejected prior to the
      above CL, but is now accepted even though it is an invalid CIDR notation.
      This CL fixes that regression.
      
      We fix this by removing the signed parsing logic entirely from dtoi.
      It was introduced relatively recently in https://golang.org/cl/12447
      to fix a bug where an invalid port was improperly being parsed as OK.
      It seems to me that the fix in that CL to the port handling logic was
      sufficient such that a change to dtoi was unnecessary.
      
      Updates #16350
      
      Change-Id: I414bb1aa27d0a226ebd4b05a09cb40d784691b43
      Reviewed-on: https://go-review.googlesource.com/28414Reviewed-by: 's avatarMatthew Dempsky <mdempsky@google.com>
      Reviewed-by: 's avatarMikio Hara <mikioh.mikioh@gmail.com>
      Run-TryBot: Joe Tsai <thebrokentoaster@gmail.com>
      3ef0e8f8
    • Robert Griesemer's avatar
      cmd/compile: add format verification test · 42433e27
      Robert Griesemer authored
      TestFormats finds potential (Printf, etc.) format strings.
      If they are used in a call, the format verbs are verified
      based on the matching argument type against a precomputed
      table of valid formats (formatMapping, below). The table
      can be used to automatically rewrite format strings with
      the -u flag.
      
      Run as: go test -run Formats [-u]
      
      A formatMapping based on the existing formats is printed
      when the test is run in verbose mode (-v flag). The table
      needs to be updated whenever a new (type, format) combination
      is found and the format verb is not 'v' (as in "%v").
      
      Known bugs:
      - indexed format strings ("%[2]s", etc.) are not suported
        (the test will fail)
      - format strings that are not simple string literals cannot
        be updated automatically
        (the test will fail with respective warnings)
      
      Change-Id: I1ca5bb6421d57ac78a00f1a80b9547a72837adc9
      Reviewed-on: https://go-review.googlesource.com/28419
      Run-TryBot: Robert Griesemer <gri@golang.org>
      TryBot-Result: Gobot Gobot <gobot@golang.org>
      Reviewed-by: 's avatarJosh Bleecher Snyder <josharian@gmail.com>
      42433e27