File tree Expand file tree Collapse file tree 2 files changed +6
-7
lines changed
main/scala-2.13/com/avsystem/commons/mongo/typed
test/scala-2.13/com/avsystem/commons/mongo/typed Expand file tree Collapse file tree 2 files changed +6
-7
lines changed Original file line number Diff line number Diff line change @@ -12,13 +12,12 @@ trait MongoPolyAdtInstances[D[_]] {
12
12
def codec [T : GenCodec ]: GenObjectCodec [D [T ]]
13
13
14
14
/**
15
- * We need to accept an implicit `GenObjectCodec[D[T]]` because materialization of
16
- * [[MongoAdtFormat ]] requires it ([[MongoAdtFormat.codec ]]). In practice, it can be derived
17
- * from the `MongoFormat[T]` that is already accepted by this method but we don't want to do this in this
18
- * trait to avoid problems with priorities of implicits. Because of that, this implicit is actually constructed
19
- * by [[AbstractMongoPolyDataCompanion.format ]].
15
+ * We need to accept an implicit `GenCodec[T]` because materialization of
16
+ * [[MongoAdtFormat ]] requires a [[GenObjectCodec ]] ([[MongoAdtFormat.codec ]]). In practice, it can be derived
17
+ * from the `MongoFormat[T]` that is already accepted by this method but we have to be careful about priority of
18
+ * implicits. Because of that, this implicit is actually provided by [[AbstractMongoPolyDataCompanion.format ]].
20
19
*/
21
- def format [T : MongoFormat ]( implicit codec : GenObjectCodec [ D [ T ]]) : MongoAdtFormat [D [T ]]
20
+ def format [T : MongoFormat : GenCodec ] : MongoAdtFormat [D [T ]]
22
21
}
23
22
24
23
abstract class AbstractMongoPolyDataCompanion [Implicits , D [_]](implicits : Implicits )(
Original file line number Diff line number Diff line change @@ -19,5 +19,5 @@ abstract class CustomPolyDataCompanion[D[_]](
19
19
* This class tests (through its compilation) if implicit resolution conflicts that were
20
20
* previously present in [[MongoPolyAdtInstances ]] are fixed.
21
21
*/
22
- case class PolyDataWithCustomImplicits [+ T ](wrappy : CustomWrappy , value : T )
22
+ case class PolyDataWithCustomImplicits [+ T ](wrappy : CustomWrappy , value : List [ T ] )
23
23
object PolyDataWithCustomImplicits extends CustomPolyDataCompanion [PolyDataWithCustomImplicits ]
You can’t perform that action at this time.
0 commit comments