applctv / gcp-scala-datastore

Scala wrapper to Google Cloud Datastore operations
15 stars 16 forks source link

Explicitly define evidence parameters #32

Open jacobg opened 5 years ago

jacobg commented 5 years ago

Many of the DatastoreService methods use ClassTags, which is syntactic sugar for adding an implicit parameter. But then you can't explicitly specify any other implicit parameters such as the ExecutionContext. The problem is discussed here: https://stackoverflow.com/questions/23718165/implicit-parameter-and-classtag

The solution is for each method to explicitly define the first implicit parameter as evidence: ClassTag[T].