From 9afc1ccfbfe6299396038202a639babeb77f73c0 Mon Sep 17 00:00:00 2001 From: Rohan Talip Date: Sun, 2 Feb 2020 05:05:56 -0800 Subject: [PATCH] Improved the grammar around type inference Also removed the negative part of the statement as it seems redundant. --- _overviews/tutorials/scala-for-java-programmers.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/_overviews/tutorials/scala-for-java-programmers.md b/_overviews/tutorials/scala-for-java-programmers.md index 3fa73ffc1b..b78a047fce 100644 --- a/_overviews/tutorials/scala-for-java-programmers.md +++ b/_overviews/tutorials/scala-for-java-programmers.md @@ -269,8 +269,8 @@ which looks at the right-hand side of these methods and deduces that both return a value of type `Double`. The compiler is not always able to infer types like it does here, and -there is unfortunately no simple rule to know exactly when it will be, -and when not. In practice, this is usually not a problem since the +there is unfortunately no simple rule to know exactly when it will be +able to. In practice, this is usually not a problem since the compiler complains when it is not able to infer a type which was not given explicitly. As a simple rule, beginner Scala programmers should try to omit type declarations which seem to be easy to deduce from the