Skip to content

Commit

Permalink
Make derived def instead of given
Browse files Browse the repository at this point in the history
  • Loading branch information
danslapman committed Jan 18, 2025
1 parent 99ec82c commit fe57bdb
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
2 changes: 1 addition & 1 deletion oolong-bson/src/main/scala/oolong/bson/BsonDecoder.scala
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ object BsonDecoder {
}
}

inline given derived[T]: BsonDecoder[T] = ${ derivedImpl[T] }
inline def derived[T]: BsonDecoder[T] = ${ derivedImpl[T] }

def derivedImpl[T: Type](using q: Quotes): Expr[BsonDecoder[T]] =
import quotes.reflect.*
Expand Down
2 changes: 1 addition & 1 deletion oolong-bson/src/main/scala/oolong/bson/BsonEncoder.scala
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ object BsonEncoder {
}
}

inline given derived[T]: BsonEncoder[T] = ${ derivedImpl[T] }
inline def derived[T]: BsonEncoder[T] = ${ derivedImpl[T] }

def derivedImpl[T: Type](using q: Quotes): Expr[BsonEncoder[T]] =
import quotes.reflect.*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@ package oolong.bson.meta

import java.time.Instant
import scala.annotation.nowarn
import scala.util.Random

import oolong.bson.meta.*
import oolong.bson.meta.queryMeta
Expand Down

0 comments on commit fe57bdb

Please sign in to comment.