@johnynek: Do you mean [NotNothing](https://github.com/mongodb/casbah/blob/master/casbah-commons/src/main/scala/Implicits.scala#L135)? If not, do you think that explicitly list all the supported types is a bit too verbose? This basically means all `Primitives` + `AnyRef`

@rubanm: I'd like to avoid specifying the concrete types, e.g. `MongoLongStore`, if it is possible. When you said _fold_ `MongoObject` and `MongoStore` into `class MongoStore[K, V](args) extends Store[MongoDbObject, MongoDbObject]`, how do you plan to handle `[String, String]`, or `[Int, Int]`?

Let me try to express the concerns I have. There are two very closely related problems:

1) Due to a bug in current casbah 2.6.4, `getAs[V]` returns `Some(v)`, event if the type does not match. E.g., for a `MongoStore[Int, Int]`, a call to `getAs[Int]()` would return `Some(haha)`, and it would fail when the user call `get()` on `Option`.

2) Internally, MongoDB does not have `Short` and `Float`. The fix to 1) was to match the actual type using `Manifest`: https://github.com/mongodb/casbah/blob/master/casbah-commons/src/main/scala/Castable.scala#L43. However, when we use `Short` and `Float`, the underlying Java object are `java.lang.Integer` and `java.lang.Double`. This basically means when you call `getAs[Short]` or `getAs[Float]`, you always get a `None`.

I want to try to avoid these two problems without forcing/limiting the actual types on the store.