Open CC007 opened 1 year ago
Sorry, auto
can't be used as a generic type argument; it is limited to locals, fields, and method return types. Your example should result in a compiler error indicating this. This will be fixed soon. Thanks for the heads-up.
Describe the bug I was trying to use
auto
as a generic parameter. This did compile, but the Manifold IntelliJ plugin wasn't happy. It created aStackOverflowError
in the "IDE Internal Errors" section (see stacktrace in gist below). There were actually 55 similar errors thrown over the time that I was experimenting with it. Some had the following text instead:With that second number changing and one exception log for almost every value of that second number, down to 2. It also threw this error:
To Reproduce Steps to reproduce the behavior:
private Map<auto, String> mapping = new HashMap<>();
Expected behavior If you're supposed to be allowed to use auto in generics, there shouldn't be any issue with doing the steps to reproduce. If you're not supposed to do this, I would expect the auto text to become red to indicate an error and for the plugin to not cause a
StackOverflowError
Screenshots This last time I added auto for creating the screenshot, this caused error 56 to 61.
Desktop (please complete the following information):
Stack trace See this gist