diff options
author | 2023-12-13 15:54:49 -0800 | |
---|---|---|
committer | 2023-12-14 16:12:21 -0800 | |
commit | ff694a8c88c632559c72653edf99f21c3d761dee (patch) | |
tree | a0b6c2a6cda60be82412b377d15d0a9b86eca065 /apex/apex.go | |
parent | 402130276c75fd967dcae894bd363edc3050d205 (diff) |
Convert Provider to generic providers API
Convert all of the callers of Provider/HasProvider to use the type-safe
android.ModuleProvider API.
Bug: 316410648
Test: builds
Change-Id: I73479de1625fa2865b6c73444cd477e50d56dc5a
Diffstat (limited to 'apex/apex.go')
-rw-r--r-- | apex/apex.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/apex/apex.go b/apex/apex.go index 9dac5ce7e..3c96ce010 100644 --- a/apex/apex.go +++ b/apex/apex.go @@ -2150,7 +2150,7 @@ func (a *apexBundle) depVisitor(vctx *visitorContext, ctx android.ModuleContext, af := apexFileForNativeLibrary(ctx, ch, vctx.handleSpecialLibs) af.transitiveDep = true - abInfo := ctx.Provider(ApexBundleInfoProvider).(ApexBundleInfo) + abInfo, _ := android.ModuleProvider(ctx, ApexBundleInfoProvider) if !abInfo.Contents.DirectlyInApex(depName) && (ch.IsStubs() || ch.HasStubsVariants()) { // If the dependency is a stubs lib, don't include it in this APEX, // but make sure that the lib is installed on the device. @@ -2589,7 +2589,7 @@ func (a *apexBundle) checkStaticLinkingToStubLibraries(ctx android.ModuleContext return } - abInfo := ctx.Provider(ApexBundleInfoProvider).(ApexBundleInfo) + abInfo, _ := android.ModuleProvider(ctx, ApexBundleInfoProvider) a.WalkPayloadDeps(ctx, func(ctx android.ModuleContext, from blueprint.Module, to android.ApexModule, externalDep bool) bool { if ccm, ok := to.(*cc.Module); ok { |