         return resolve(key: Key(type: T.self, name: Name.default, container: Name.default), parameter: parameter, cached: cached)
     }
     
-    private static func metathunk<M>(_ metafilter: @escaping Metafilter<M>) -> Metafilter<Any> {
+    /**
+     Provides a thunk between `Metafilter<M>` and `Metafilter<Any>`.
+     
+     Checks to make sure that the metadata being checked actually is of type `M`.
+    */
+    private static func metathunk<M>(_ metafilter: @escaping Metafilter<M>) -> Metathunk {
         return {
             guard let metadata = $0 as? M else { return false }
             return metafilter(metadata)
         }
     }
     
-    private static func filter(type: String?, name: AnyHashable?, container: AnyHashable?, metafilter: Metafilter<Any>? = nil) -> [Key] {
+    /**
+     Most of the `filter` overloads end up here.
+    */
+    private static func filter(type: String?, name: AnyHashable?, container: AnyHashable?, metafilter: Metathunk? = nil) -> [Key] {
         return lock.read {
             var keys = [Key]()
             for (key, dependency) in registrations {

        return exists(type: String(reflecting: type), name: nil, container: nil, metafilter: nil)
    }
    
    public static func exists<M>(metafilter: @escaping Metafilter<M>) -> Bool {
        return exists(type: nil, name: nil, container: nil, metafilter: metathunk(metafilter))
    }

    /**
     Helper method for filtering.
     */
    private static func exists(type: String?, name: AnyHashable?, container: AnyHashable?, metafilter: Metathunk? = nil) -> Bool {
        return lock.read {
            for (key, dependency) in registrations {
                if let type = type, type != key.type { continue }
