Go rules: several small fixes for analysis performance (#1026)

* Go rules: several small fixes for analysis performance

* Duplicated direct deps in emit_archive and srcs in emit_library. The
  former change caused #1023, though I don't fully understand why.
* In _go_archive_aspect_impl, direct now contains deps from library,
  not library itself.
* In emit_archive, transitive is built using the depset
  constructor. We no longer iterate over transitive.

TODO: understand depset performance and optimize all depset use.

Fixes #1023

* use old depset constructor since new one not supported in Bazel 0.6
2 files changed