Fixed
Status Update
Comments
ja...@google.com <ja...@google.com>
ja...@google.com <ja...@google.com> #2
Should land in the next week's release (i.e., not the release happening this coming week)
Description
Using Android Studio 3.6 Canary 11 and com.android.tools.build:gradle:3.6.0-alpha11 with viewBinding set to enabled, I observed an issue when a custom view is used in a layout that is declared under a package structure starting with an uppercase letter. During the generation of the Binding class, the compiler throws the following message:
Cause: couldn't make a guess for me.monori.viewbindingtest.Sentencecase.view.CustomButton
Please see attached zip as an example project showcasing the issue
With a brief chat with JakeW, he pointed out that the cause of this could be that ViewBinding (and actually DataBindings too) rely on ClassName.bestGuess from JavaPoet which does not work well with packages containing uppercase letter at start.
Thanks!