1
0
mirror of https://github.com/golang/go synced 2024-10-01 15:58:33 -06:00
Commit Graph

6 Commits

Author SHA1 Message Date
Alan Donovan
b56ef30191 tools: updates for minimum Go version 1.6
Details:
- remove go1.5 "default version" labels on most files
- remove go1.6 labels on a few files
- go/loader: use conf.Cwd not "." in a couple places; update faulty
  test expectations.  (Not sure why this wasn't caught sooner.)
- go/ssa/interp: add 'mono' result to time.now intrinsic
- go/gcimporter15/bimport.go: make consistent with the version in gc
- go/ssa/interp: update test error message
- go/ssa: update a comment

The go/gcimporter15/bexport.go logic is stale and needs to be brought
up to date.  Needs a separate CL since it's tricky.

Tested on go1.6, go1.7, go1.8.

Change-Id: I841189d30e131b7c49a4e8690ea7c40b55041bae
Reviewed-on: https://go-review.googlesource.com/36540
Reviewed-by: Robert Griesemer <gri@golang.org>
2017-02-07 21:06:19 +00:00
Alan Donovan
542ffc7e75 tools: switch to standard go/types at tip
A few files have been forked and tagged "go1.5,!go1.6" to work around
minor API changes between the two types packages:
- constant.Value.String() in oracle/describe.go and its tests;
- constant.ToInt must now be called before constant.Int64Val.
- types.Config{Importer: importer.Default()} in a number of places
- go/types/typeutil/import_test.go uses lowercase names to avoid 'import "C"'.

Files in go/types/typesutil, missing from my previous CL, have been
tagged !go1.5; these files will be deleted in February.

All affected packages were tested using 1.4.1, 1.5, and ~1.6 (tip).

Change-Id: Iec7fd370e1434508149b378438fb37f65b8d2ba8
Reviewed-on: https://go-review.googlesource.com/18207
Reviewed-by: Robert Griesemer <gri@golang.org>
2016-01-06 22:15:26 +00:00
Alan Donovan
2477c0d578 x/tools/...: fork and tag !1.5 all files that use go/types et al
This change will ensure that the tree continues to work with go1.4.1.

All files continue to depend on golang.org/x/tools/go/types, but in a
follow-up change, I will switch the primary files to depend on the
standard go/types package.  Another (smaller) set of files will be
forked and tagged, this time !1.6, due to API differences between the
two packages.

All tests pass using 1.4.1, 1.5, and ~1.6 (tip).

Change-Id: Ifd75a6330e120957d646be91693daaba1ce0e8c9
Reviewed-on: https://go-review.googlesource.com/18333
Reviewed-by: Robert Griesemer <gri@golang.org>
2016-01-06 20:40:09 +00:00
Robert Griesemer
3f8eecd15b go/types: move MethodSetCache into package go/types/typeutil
Change-Id: Iba5d7c2df533948a5b28373b077cc0476a6745ad
Reviewed-on: https://go-review.googlesource.com/10770
Reviewed-by: Alan Donovan <adonovan@google.com>
2015-06-05 17:34:01 +00:00
Andrew Gerrand
5ebbcd132f go.tools: use golang.org/x/... import paths
Rewrite performed with this command:
  sed -i '' 's_code.google.com/p/go\._golang.org/x/_g' \
    $(grep -lr 'code.google.com/p/go.' *)

LGTM=rsc
R=rsc
CC=golang-codereviews
https://golang.org/cl/170920043
2014-11-10 08:50:40 +11:00
Alan Donovan
80c4f06c0f go.tools/godoc: server mode: add support for type and pointer analysis.
See analysis.go for overview of new features.
See README for known bugs and issues.

Much UI polish, testing and optimization work remains, but
this is a starting point.

Flag: we add a new flag -analysis=type,pointer, default "",
for adventurous users only at this stage.
Type analysis takes ~10s for stdlib + go.tools;
Pointer analysis (currently) takes several minutes.

Dependencies: we now include jquery.treeview.js and its GIF
images among the resources.  (bake.go now handles binary.)

LGTM=crawshaw, bgarcia
R=crawshaw, bgarcia
CC=bradfitz, golang-codereviews
https://golang.org/cl/60540044
2014-03-14 18:58:22 -04:00