bazel packages: move lib.syntax.Type here
Type is a concept of the build language, not of core Starlark.
(Witness all the references to Label. That said, there appear to be
three concepts---BuildType, Type, StarlarkType---where only two
are necessary: the types of rule attributes, and a library of
Starlark-to-Java conversion combinators.)
This change is mostly mechanical, except:
- MethodLibrary: two uses of Type.XYZ.convert replaced by ad-hoc code.
- SkylarkDict: getDictFromArgs substantially rewritten to avoid Type.
Its error messages were improved.
I added comments re: harmful type parameterization.
This CL depends on unknown commit, which first breaks
Copybara's dependency on syntax.Type.
PiperOrigin-RevId: 267694761
diff --git a/src/main/java/com/google/devtools/build/lib/analysis/TargetConfiguredEvent.java b/src/main/java/com/google/devtools/build/lib/analysis/TargetConfiguredEvent.java
index 9cba211..d749cba 100644
--- a/src/main/java/com/google/devtools/build/lib/analysis/TargetConfiguredEvent.java
+++ b/src/main/java/com/google/devtools/build/lib/analysis/TargetConfiguredEvent.java
@@ -27,7 +27,7 @@
import com.google.devtools.build.lib.packages.Target;
import com.google.devtools.build.lib.packages.TargetUtils;
import com.google.devtools.build.lib.packages.TestSize;
-import com.google.devtools.build.lib.syntax.Type;
+import com.google.devtools.build.lib.packages.Type;
import java.util.Collection;
/** Event reporting about the configurations associated with a given target */