From b178e4658b3066b3f2cb2210bc57af9e8de71868 Mon Sep 17 00:00:00 2001 From: Martin Odersky Date: Fri, 31 Mar 2006 16:06:10 +0000 Subject: added conversion from methods to functions usin... added conversion from methods to functions using prefix operator `&' --- src/compiler/scala/tools/nsc/typechecker/Typers.scala | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/compiler') diff --git a/src/compiler/scala/tools/nsc/typechecker/Typers.scala b/src/compiler/scala/tools/nsc/typechecker/Typers.scala index 680de70cf9..8637ff3a60 100644 --- a/src/compiler/scala/tools/nsc/typechecker/Typers.scala +++ b/src/compiler/scala/tools/nsc/typechecker/Typers.scala @@ -387,8 +387,8 @@ trait Typers requires Analyzer { error(tree.pos, migrateMsg + " method can be converted to function only if an expected function type is given"); else error(tree.pos, "missing arguments for "+tree.symbol+tree.symbol.locationString+ - if (tree.symbol.isConstructor) "" - else ";\nprefix this method with `&' if you want to treat it as a partially applied function") + (if (tree.symbol.isConstructor) "" + else ";\nprefix this method with `&' if you want to treat it as a partially applied function")) } setError(tree) } -- cgit v1.2.3