Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Request: add inspection of suggesting to add annotations of WorkerThread/UiThread/AnyThread based on usage #32

Open
AndroidDeveloperLB opened this issue Jul 6, 2022 · 2 comments

Comments

@AndroidDeveloperLB
Copy link

If in all calls of a function "foo", we call it from the UI-thread, it could suggest us to add the UiThread annotation.
Same for WorkerThread.
If it's mixed, suggest to add "AnyThread" annotation.

You can also add a setting of how far to suggest, because if a function is private, it's safer to use the quick-fix than when it's public.
That's especially important for the case of library-modules.

@Miha-x64
Copy link
Owner

Miha-x64 commented Sep 2, 2022

Sounds useful, I'd accept a contribution.

@AndroidDeveloperLB
Copy link
Author

@Miha-x64 Hopefully someone could offer it. For now I've also requested this on the issue tracker:
https://issuetracker.google.com/issues/244694784

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

No branches or pull requests

2 participants