File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -132,7 +132,7 @@ object desugar {
132
132
case tparam @ TypeDef (_, ContextBounds (tbounds, cxbounds)) =>
133
133
for (cxbound <- cxbounds) {
134
134
val paramFlags : FlagSet = if (isPrimaryConstructor) PrivateLocalParamAccessor else Param
135
- val epname = (nme.EVIDENCE_PARAM_PREFIX .toString + epbuf.length ).toTermName
135
+ val epname = ctx.freshName (nme.EVIDENCE_PARAM_PREFIX ).toTermName
136
136
epbuf += ValDef (epname, cxbound, EmptyTree ).withFlags(paramFlags | Implicit )
137
137
}
138
138
cpy.TypeDef (tparam)(rhs = tbounds)
Original file line number Diff line number Diff line change
1
+ class First [A ]
2
+ class Second [A ]
3
+
4
+ class Foo {
5
+ def foo [A : First ] = {
6
+ def bar [B : Second ] = {
7
+ val fst : First [A ] = implicitly[First [A ]]
8
+ val snd : Second [B ] = implicitly[Second [B ]]
9
+ }
10
+ }
11
+ }
You can’t perform that action at this time.
0 commit comments