rpau / javalang-compiler

Java compiler elements (symbol and type tables) to perform code semantic analysis
GNU Lesser General Public License v3.0
10 stars 4 forks source link

Fix to support MethodReferenceExpr as statements #78

Closed rpau closed 6 years ago

rpau commented 6 years ago

The system was assuming that method references could be only used from arguments to run lambda expressions.

However, functions such as Supplier can also be instantiated as method references.

This patch fixes it by recursively analyzing the scope of the scope if it has not been analyzed before.