@@ -127,7 +127,7 @@ class JSCodeGen()(implicit ctx: Context) {
127127 /* Finally, we emit true code for the remaining class defs. */
128128 for (td <- allTypeDefs) {
129129 val sym = td.symbol
130- implicit val pos : Position = sym.pos
130+ implicit val pos = sym.pos
131131
132132 /* Do not actually emit code for primitive types nor scala.Array. */
133133 val isPrimitive =
@@ -203,7 +203,7 @@ class JSCodeGen()(implicit ctx: Context) {
203203 */
204204 private def genScalaClass (td : TypeDef ): js.ClassDef = {
205205 val sym = td.symbol.asClass
206- implicit val pos : Position = sym.pos
206+ implicit val pos = sym.pos
207207
208208 assert(! sym.is(Trait ),
209209 " genScalaClass() must be called only for normal classes: " + sym)
@@ -336,7 +336,7 @@ class JSCodeGen()(implicit ctx: Context) {
336336 */
337337 private def genRawJSClassData (td : TypeDef ): js.ClassDef = {
338338 val sym = td.symbol.asClass
339- implicit val pos : Position = sym.pos
339+ implicit val pos = sym.pos
340340
341341 val classIdent = encodeClassFullNameIdent(sym)
342342 val superClass =
@@ -358,7 +358,7 @@ class JSCodeGen()(implicit ctx: Context) {
358358 */
359359 private def genInterface (td : TypeDef ): js.ClassDef = {
360360 val sym = td.symbol.asClass
361- implicit val pos : Position = sym.pos
361+ implicit val pos = sym.pos
362362
363363 val classIdent = encodeClassFullNameIdent(sym)
364364
@@ -408,7 +408,7 @@ class JSCodeGen()(implicit ctx: Context) {
408408 f <- classSym.info.decls
409409 if ! f.is(Method ) && f.isTerm
410410 } yield {
411- implicit val pos : Position = f.pos
411+ implicit val pos = f.pos
412412
413413 val name =
414414 /* if (isExposed(f)) js.StringLiteral(jsNameOf(f))
@@ -479,7 +479,7 @@ class JSCodeGen()(implicit ctx: Context) {
479479 * Other (normal) methods are emitted with `genMethodBody()`.
480480 */
481481 private def genMethodWithCurrentLocalNameScope (dd : DefDef ): Option [js.MethodDef ] = {
482- implicit val pos : Position = dd.pos
482+ implicit val pos = dd.pos
483483 val sym = dd.symbol
484484 val vparamss = dd.vparamss
485485 val rhs = dd.rhs
@@ -501,7 +501,7 @@ class JSCodeGen()(implicit ctx: Context) {
501501 val methodName : js.PropertyName = encodeMethodSym(sym)
502502
503503 def jsParams = for (param <- params) yield {
504- implicit val pos : Position = param.pos
504+ implicit val pos = param.pos
505505 js.ParamDef (encodeLocalSym(param), toIRType(param.info),
506506 mutable = false , rest = false )
507507 }
@@ -574,13 +574,13 @@ class JSCodeGen()(implicit ctx: Context) {
574574 private def genMethodDef (static : Boolean , methodName : js.PropertyName ,
575575 paramsSyms : List [Symbol ], resultIRType : jstpe.Type ,
576576 tree : Tree , optimizerHints : OptimizerHints ): js.MethodDef = {
577- implicit val pos : Position = tree.pos
577+ implicit val pos = tree.pos
578578
579579 ctx.debuglog(" genMethod " + methodName.name)
580580 ctx.debuglog(" " )
581581
582582 val jsParams = for (param <- paramsSyms) yield {
583- implicit val pos : Position = param.pos
583+ implicit val pos = param.pos
584584 js.ParamDef (encodeLocalSym(param), toIRType(param.info),
585585 mutable = false , rest = false )
586586 }
@@ -621,7 +621,7 @@ class JSCodeGen()(implicit ctx: Context) {
621621 /* Any JavaScript expression is also a statement, but at least we get rid
622622 * of some pure expressions that come from our own codegen.
623623 */
624- implicit val pos : Position = tree.pos
624+ implicit val pos = tree.pos
625625 tree match {
626626 case js.Block (stats :+ expr) => js.Block (stats :+ exprToStat(expr))
627627 case _:js.Literal | js.This () => js.Skip ()
@@ -644,7 +644,7 @@ class JSCodeGen()(implicit ctx: Context) {
644644 * is transformed into an equivalent portion of the JS AST.
645645 */
646646 private def genStatOrExpr (tree : Tree , isStat : Boolean ): js.Tree = {
647- implicit val pos : Position = tree.pos
647+ implicit val pos = tree.pos
648648
649649 ctx.debuglog(" " + tree)
650650 ctx.debuglog(" " )
@@ -902,7 +902,7 @@ class JSCodeGen()(implicit ctx: Context) {
902902 * primitives, JS calls, etc. They are further dispatched in here.
903903 */
904904 private def genApply (tree : Apply , isStat : Boolean ): js.Tree = {
905- implicit val pos : Position = tree.pos
905+ implicit val pos = tree.pos
906906 val args = tree.args
907907 val sym = tree.fun.symbol
908908
@@ -951,7 +951,7 @@ class JSCodeGen()(implicit ctx: Context) {
951951 * irrelevant.
952952 */
953953 private def genSuperCall (tree : Apply , isStat : Boolean ): js.Tree = {
954- implicit val pos : Position = tree.pos
954+ implicit val pos = tree.pos
955955 val Apply (fun @ Select (sup @ Super (_, mix), _), args) = tree
956956 val sym = fun.symbol
957957
@@ -987,7 +987,7 @@ class JSCodeGen()(implicit ctx: Context) {
987987 * * regular new
988988 */
989989 private def genApplyNew (tree : Apply ): js.Tree = {
990- implicit val pos : Position = tree.pos
990+ implicit val pos = tree.pos
991991
992992 val Apply (fun @ Select (New (tpt), nme.CONSTRUCTOR ), args) = tree
993993 val ctor = fun.symbol
@@ -1023,7 +1023,7 @@ class JSCodeGen()(implicit ctx: Context) {
10231023 private def genPrimitiveOp (tree : Apply , isStat : Boolean ): js.Tree = {
10241024 import scala .tools .nsc .backend .ScalaPrimitives ._
10251025
1026- implicit val pos : Position = tree.pos
1026+ implicit val pos = tree.pos
10271027
10281028 val Apply (fun, args) = tree
10291029 val receiver = qualifierOf(fun)
@@ -1063,7 +1063,7 @@ class JSCodeGen()(implicit ctx: Context) {
10631063 private def genSimpleUnaryOp (tree : Apply , arg : Tree , code : Int ): js.Tree = {
10641064 import scala .tools .nsc .backend .ScalaPrimitives ._
10651065
1066- implicit val pos : Position = tree.pos
1066+ implicit val pos = tree.pos
10671067
10681068 val genArg = genExpr(arg)
10691069 val resultIRType = toIRType(tree.tpe)
@@ -1118,7 +1118,7 @@ class JSCodeGen()(implicit ctx: Context) {
11181118 }
11191119 import OpTypes ._
11201120
1121- implicit val pos : Position = tree.pos
1121+ implicit val pos = tree.pos
11221122
11231123 val lhsIRType = toIRType(lhs.tpe)
11241124 val rhsIRType = toIRType(rhs.tpe)
@@ -1374,7 +1374,7 @@ class JSCodeGen()(implicit ctx: Context) {
13741374 */
13751375 private def genStringConcat (tree : Apply , receiver : Tree ,
13761376 args : List [Tree ]): js.Tree = {
1377- implicit val pos : Position = tree.pos
1377+ implicit val pos = tree.pos
13781378
13791379 val arg = args.head
13801380
@@ -1401,7 +1401,7 @@ class JSCodeGen()(implicit ctx: Context) {
14011401
14021402 /** Gen JS code for a call to Any.## */
14031403 private def genScalaHash (tree : Apply , receiver : Tree ): js.Tree = {
1404- implicit val pos : Position = tree.pos
1404+ implicit val pos = tree.pos
14051405
14061406 genModuleApplyMethod(defn.ScalaRuntimeModule .requiredMethod(nme.hash_),
14071407 List (genExpr(receiver)))
@@ -1411,7 +1411,7 @@ class JSCodeGen()(implicit ctx: Context) {
14111411 private def genArrayOp (tree : Tree , code : Int ): js.Tree = {
14121412 import scala .tools .nsc .backend .ScalaPrimitives ._
14131413
1414- implicit val pos : Position = tree.pos
1414+ implicit val pos = tree.pos
14151415
14161416 val Apply (fun, args) = tree
14171417 val arrayObj = qualifierOf(fun)
@@ -1462,7 +1462,7 @@ class JSCodeGen()(implicit ctx: Context) {
14621462 // common case for which there is no side-effect nor NPE
14631463 genArg
14641464 case _ =>
1465- implicit val pos : Position = tree.pos
1465+ implicit val pos = tree.pos
14661466 /* TODO Check for a null receiver?
14671467 * In theory, it's UB, but that decision should be left for link time.
14681468 */
@@ -1474,7 +1474,7 @@ class JSCodeGen()(implicit ctx: Context) {
14741474 private def genCoercion (tree : Apply , receiver : Tree , code : Int ): js.Tree = {
14751475 import scala .tools .nsc .backend .ScalaPrimitives ._
14761476
1477- implicit val pos : Position = tree.pos
1477+ implicit val pos = tree.pos
14781478
14791479 val source = genExpr(receiver)
14801480
@@ -1544,7 +1544,7 @@ class JSCodeGen()(implicit ctx: Context) {
15441544
15451545 /** Gen a call to the special `throw` method. */
15461546 private def genThrow (tree : Apply , args : List [Tree ]): js.Tree = {
1547- implicit val pos : Position = tree.pos
1547+ implicit val pos = tree.pos
15481548 val exception = args.head
15491549 val genException = genExpr(exception)
15501550 js.Throw {
@@ -1568,7 +1568,7 @@ class JSCodeGen()(implicit ctx: Context) {
15681568 * * Regular method call
15691569 */
15701570 private def genNormalApply (tree : Apply , isStat : Boolean ): js.Tree = {
1571- implicit val pos : Position = tree.pos
1571+ implicit val pos = tree.pos
15721572
15731573 val fun = tree.fun match {
15741574 case fun : Ident => desugarIdent(fun).get
@@ -1616,7 +1616,7 @@ class JSCodeGen()(implicit ctx: Context) {
16161616 superIn : Option [Symbol ] = None )(
16171617 implicit pos : Position ): js.Tree = {
16181618
1619- implicit val pos : Position = tree.pos
1619+ implicit val pos = tree.pos
16201620
16211621 def noSpread = ! args.exists(_.isInstanceOf [js.JSSpread ])
16221622 val argc = args.size // meaningful only for methods that don't have varargs
@@ -1775,7 +1775,7 @@ class JSCodeGen()(implicit ctx: Context) {
17751775 * primitive instead.)
17761776 */
17771777 private def genTypeApply (tree : TypeApply ): js.Tree = {
1778- implicit val pos : Position = tree.pos
1778+ implicit val pos = tree.pos
17791779
17801780 val TypeApply (fun, targs) = tree
17811781
@@ -1803,7 +1803,7 @@ class JSCodeGen()(implicit ctx: Context) {
18031803
18041804 /** Gen JS code for a Java Seq literal. */
18051805 private def genJavaSeqLiteral (tree : JavaSeqLiteral ): js.Tree = {
1806- implicit val pos : Position = tree.pos
1806+ implicit val pos = tree.pos
18071807
18081808 val genElems = tree.elems.map(genExpr)
18091809 val arrayType = toReferenceType(tree.tpe).asInstanceOf [jstpe.ArrayType ]
@@ -1852,7 +1852,7 @@ class JSCodeGen()(implicit ctx: Context) {
18521852 * available in the `body`.
18531853 */
18541854 private def genClosure (tree : Closure ): js.Tree = {
1855- implicit val pos : Position = tree.pos
1855+ implicit val pos = tree.pos
18561856 val Closure (env, call, functionalInterface) = tree
18571857
18581858 val envSize = env.size
@@ -1868,7 +1868,7 @@ class JSCodeGen()(implicit ctx: Context) {
18681868 val allCaptureValues = qualifier :: env
18691869
18701870 val (formalCaptures, actualCaptures) = allCaptureValues.map { value =>
1871- implicit val pos : Position = value.pos
1871+ implicit val pos = value.pos
18721872 val formalIdent = value match {
18731873 case Ident (name) => freshLocalIdent(name.toString)
18741874 case This (_) => freshLocalIdent(" this" )
@@ -1988,7 +1988,7 @@ class JSCodeGen()(implicit ctx: Context) {
19881988
19891989 /** Gen JS code for an isInstanceOf test (for reference types only) */
19901990 private def genIsInstanceOf (tree : Tree , value : js.Tree , to : Type ): js.Tree = {
1991- implicit val pos : Position = tree.pos
1991+ implicit val pos = tree.pos
19921992 val sym = to.widenDealias.typeSymbol
19931993
19941994 if (sym == defn.ObjectClass ) {
@@ -2242,7 +2242,7 @@ class JSCodeGen()(implicit ctx: Context) {
22422242 * to perform the conversion to js.Array, then wrap in a Spread
22432243 * operator.
22442244 */
2245- implicit val pos : Position = arg.pos
2245+ implicit val pos = arg.pos
22462246 val jsArrayArg = genModuleApplyMethod(
22472247 jsdefn.RuntimePackage_genTraversableOnce2jsArray ,
22482248 List (genExpr(arg)))
@@ -2259,7 +2259,7 @@ class JSCodeGen()(implicit ctx: Context) {
22592259 */
22602260 private def tryGenRepeatedParamAsJSArray (arg : Tree ,
22612261 handleNil : Boolean ): Option [List [js.Tree ]] = {
2262- implicit val pos : Position = arg.pos
2262+ implicit val pos = arg.pos
22632263
22642264 // Given a method `def foo(args: T*)`
22652265 arg match {
0 commit comments