Remove IsDependencyRoot from interface
This is equivalent to Binary() -- reduce the interface and improve
clarity.
Test: go test soong tests
Change-Id: I770f5ce79fd4d888586d31ec5e67be88153626b6
diff --git a/cc/sanitize.go b/cc/sanitize.go
index 4cc70e0..e95a935 100644
--- a/cc/sanitize.go
+++ b/cc/sanitize.go
@@ -1250,7 +1250,7 @@
func sanitizerMutator(t SanitizerType) func(android.BottomUpMutatorContext) {
return func(mctx android.BottomUpMutatorContext) {
if c, ok := mctx.Module().(PlatformSanitizeable); ok && c.SanitizePropDefined() {
- if c.IsDependencyRoot() && c.IsSanitizerEnabled(t) {
+ if c.Binary() && c.IsSanitizerEnabled(t) {
modules := mctx.CreateVariations(t.variationName())
modules[0].(PlatformSanitizeable).SetSanitizer(t, true)
} else if c.IsSanitizerEnabled(t) || c.SanitizeDep() {