Skip to content

Conversation

shaomaicheng
Copy link

Reason for the change:

Based on the issue: #779

Bug reason:

When upgrading Kotlin or base library versions, some libraries that use KotlinPoet may also be upgraded to version 1.11 or higher.

KotlinPoet 1.11.0 has the following release note:

• Fix: Enforce only allowed parameter modifiers in ParameterSpec (i.e. crossinline, vararg, and noinline).

For more details, please refer to: https://github.com/square/kotlinpoet/releases

When generating the PermissionRequest class for methods annotated with @NeedsPermission, the private constructor will cause an error.

Reproduction steps:

Upgrade KotlinPoet to 1.11.0
Add a new parameter "callback" to the MainActivity#showCamera method in the sample Modification:

Do not pass the KModifier.*PRIVATE parameter

Reason for the change:

Based on the issue: permissions-dispatcher#779

Bug reason:

When upgrading Kotlin or base library versions, some libraries that use KotlinPoet may also be upgraded to version 1.11 or higher.

KotlinPoet 1.11.0 has the following release note:

• Fix: Enforce only allowed parameter modifiers in ParameterSpec (i.e. crossinline, vararg, and noinline).

For more details, please refer to: https://github.com/square/kotlinpoet/releases

When generating the PermissionRequest class for methods annotated with @NeedsPermission, the private constructor will cause an error.

Reproduction steps:

Upgrade KotlinPoet to 1.11.0
Add a new parameter "callback" to the MainActivity#showCamera method in the sample
Modification:

Do not pass the KModifier.*PRIVATE parameter
@shaomaicheng
Copy link
Author

@hotchemi

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant