I have declared a mutable list and I want to add a...
# intellij
v
I have declared a mutable list and I want to add an element to this list, but IDEA doesn’t show
add()
as an available method. Though, if I ignore it and type in
list.add(version)
then it compiles and works as expected. Am I doing smth wrong here? Or it’s rather a bug?
w
Is it in main sourceset or in tests? There was a bug a while back that IJ wouldn’t autocomplete some standard library methods in tests sources
🙏 1
a
Right, this may be https://youtrack.jetbrains.com/issue/KT-33516#focus=streamItem-27-3686908.0-0. Failed to reproduce in a dummy project. Do you use AS with a
buildSrc
module?
👍 1
v
Yes, my code is under
src/test/kotlin