Potential breaking changes:
- Enabled strict compile-time validation of duplicate map multibinding keys across component and subcomponent hierarchies by default (
-Adagger.mapMultibindingDuplicateDetectionFix=ENABLED). To temporarily restore the legacy lenient behavior, pass-Adagger.mapMultibindingDuplicateDetectionFix=DISABLED. See Compiler Options for more details. (13241a926) - Enabled strict
@AssistedInjectvalidation by default (-Adagger.strictAssistedInjectValidation=ENABLED), failing compilation if a library defining an@AssistedInjectclass did not run the Dagger annotation processor (which previously compiled by chance infastInitmode). To temporarily opt out, pass-Adagger.strictAssistedInjectValidation=DISABLED. (7ef8c54c0) - Fixed Dagger validation to correctly identify and reject private Kotlin classes and members, which may surface new compile-time errors on previously accepted private Kotlin declarations. (b302547ce)
Bug fixes:
- Fixes #4739: Fixed an issue where R8 could horizontally merge or inline nested
@LazyClassKeyand@HiltViewModelclasses. (2d7cea474) - Fixes #5296: Fixed an issue where
@ActivityRetainedSavedStateSavedStateHandlefails to restore if accessed for the first time after a configuration change. (b3dc7eee1) - Fixes #5407: Fixed an issue where eager tasks.withType(JavaCompile) configuration caused hiltJavaCompile to lose -Adagger.fastInit=enabled and other Hilt processor options (4d86ded0e).
- Fixes #4834: Added support for Kotlin Multiplatform Android Library projects (
com.android.kotlin.multiplatform.library) in the Hilt Gradle plugin. (6dd848a5b) - Fixed
HiltGradlePluginso unit test variants respect Gradle module exclusions and dependency substitutions on unit test classpaths. (dc8ce1db1) - Fixed cross-package visibility errors in
fastInitmode for@AssistedFactorytypes whose declarations, members, or signature types are package-private or Kotlininternalby generating apublic[FactoryName]_Proxyinterface in the factory's package. (962495001) - Fixed incompatibly scoped binding validation for module binding graphs to allow a module to declare bindings across multiple scopes. (5fc2b5dfe)