perf: mark Compose state types as @Immutable

Compose compiler reports showed DownloadState's sealed root as Uncertain
and DownloadProgressState/SettingsUiState as runtime stability, so
skippability checks were deferred to runtime. The annotations make them
compile-time stable and turn any future mutable field into an explicit
contract break.
This commit is contained in:
OneWay committed 2026-09-01 17:28:17 +08:00
1 parent 96461bd7cf
commit 5151665216
5 files changed
+15

No files matched your search

@@ -1,5 +1,8 @@
package com.example.research
import androidx.compose.runtime.Immutable
@Immutable
sealed interface DictionaryStatus {
data object Unknown : DictionaryStatus
data object Checking : DictionaryStatus