Generic type parameters inference in method chaining
问题 After reading this question, I've started to think about generic methods in Java 8 . Specifically, what happens with generic type parameters when methods are chained. For this question, I will use some generic methods from Guava's ImmutableMap , but my question is more general and can be applied to all chained generic methods. Consider ImmutableMap.of generic method, which has this signature: public static <K, V> ImmutableMap<K, V> of(K k1, V v1) If we use this generic method to declare a Map