上游 · Kotlin compiler options · Common
Kotlin contract options
The following options enable experimental Kotlin contract features.
-Xallow-contracts-on-more-functions
Enables contracts in additional declarations, including property accessors, specific operator functions, and type assertions on generic types.
-Xallow-condition-implies-returns-contracts
Allows using the returnsNotNull() function in contracts to assume a non-null return value for specified conditions.
-Xallow-holdsin-contract…