This inspection removes a single letter prefix (e.g. mFunction --> function).
It does not check if the resulting property/variable name is a keyword (e.g. kClass --> class) which generates invalid code which further inspections will trip over and fail with an exception.
Expected behavior
The inspection generates valid code (imho not renaming affected properties) if the renaming would result in a language keyword.
Observed behavior
com.pinterest.ktlint.core.ParseException: 17:8 Expecting property name or receiver type on a subsequent inspection because it fails to parse the code.
Describe the bug
This inspection removes a single letter prefix (e.g.
mFunction
-->function
). It does not check if the resulting property/variable name is a keyword (e.g.kClass
-->class
) which generates invalid code which further inspections will trip over and fail with an exception.Expected behavior
The inspection generates valid code (imho not renaming affected properties) if the renaming would result in a language keyword.
Observed behavior
com.pinterest.ktlint.core.ParseException: 17:8 Expecting property name or receiver type
on a subsequent inspection because it fails to parse the code.Steps to Reproduce
Environment information