pebble-intellij icon indicating copy to clipboard operation
pebble-intellij copied to clipboard

Pebvariable annotations for arrays don't set the correct type for objects inside the array

Open grishka opened this issue 3 years ago • 1 comments

If you write this:

{# @pebvariable name="results" type="smithereen.data.SearchResult[]" #}
{% for res in results %}
...
{% endfor %}

The plugin won't pick up the type of the objects in the array, instead thinking they're java.lang.Objects: Снимок экрана 2021-07-10 в 13 33 13 Or maybe I'm not specifying arrays/collections correctly, but adding [] is the most obvious way so it would make sense to support it if it's not supported.

grishka avatar Jul 10 '21 10:07 grishka

Trying to output a property of an array element produces an even weirder error: Снимок экрана 2021-07-10 в 13 45 30

grishka avatar Jul 10 '21 10:07 grishka

FTR subtypes of java.lang.Iterable and scala.collection.Iterable are already supported: image

I'll throw in support for arrays too.

bjansen avatar Mar 01 '24 12:03 bjansen