// ReSharper restore UnusedParameter.Global

        private static bool CacheDuckResult(
            bool calculatedResult,
            bool allowFuzzy,
            Type from,
            Type to)
        {
            DuckableTypesCache.CacheDuckable(
                from, to, calculatedResult, allowFuzzy
                );
            return(calculatedResult);
        }
        internal static bool InternalCanDuckAs(this object src, Type toType, bool allowFuzzy, bool throwOnError)
        {
            var asDictionary = TryConvertToDictionary(src);

            if (asDictionary != null)
            {
                return(asDictionary.CanDuckDictionaryAs(toType, allowFuzzy, throwOnError));
            }
            var srcType = src.GetType();

            return(DuckableTypesCache.CanDuckAs(srcType, toType, allowFuzzy) ||
                   CacheDuckResult(
                       InternalCanDuckAs(toType, srcType, allowFuzzy, throwOnError),
                       allowFuzzy,
                       srcType,
                       toType
                       ));
        }