concept type in category clojure

This is an excerpt from Manning's book Clojure: The Essential Reference.
Source lines/column references might be different, but the message says that there are at least two places where the compiler is unable to infer the types and is using reflection. If in our example we assume peaks of 100k transactions per second, we might want to review how
sign-requestis performing. Advanced tools like Criterium [19] are always the suggested choice for benchmarking, but in this specific case we can clearly see what happens just by usingtime:
[a b nil]when "a" and "b" don’t have anything in common or when the types of "a" and "b" are not compatible (see below).
(require '[clojure.string :as str]) (defn grep-by-type [q ext] ; #1 (sequence (comp (remove (memfn isDirectory)) ; #2 (map (memfn getAbsolutePath)) ; #3 (filter #(= ext (last (str/split % #"\.")))) ; #4 (filter #(str/includes? (slurp %) q))) ; #5 (file-seq (java.io.File. ".")))) (grep-by-type "file-seq" "adoc") ;; ("/Users/reborghttps://livebook.manning.com/book/./manuscript/08-Sequential-Generation.adoc")

This is an excerpt from Manning's book Get Programming with Clojure.
Clojure is a dynamically typed programming language. It means that values have a type and their types are determined at run time. Therefore, the type doesn't have to be explicitly specified by the developer.
A cool thing in Clojure is that the types of the values are accessible by us - the Clojure developers - without requiring any reflection or meta-programming capabilities. There is a function called type that returns the type of its argument.
Let’s starting by exploring the types of numbers:
user=> (type 42) java.lang.Long user=> (type 42.1) java.lang.DoubleWhat about the types of true and false?

This is an excerpt from Manning's book The Joy of Clojure, Second Edition.
Polymorphism is the ability of a function or method to perform different actions depending on the type of its arguments or a target object. Clojure provides polymorphism via protocols,[13] which let you attach a set of behaviors to any number of existing types and classes; they’re similar to what are sometimes called mix-ins, traits, or interfaces in other languages and are more open and extensible than polymorphism in many languages.
(def clueless 9) (class clueless) ;=> java.lang.Long #1 (class (+ clueless 9000000000000000)) ;=> java.lang.Long #2 (class (+ clueless 90000000000000000000)) ;=> clojure.lang.BigInt #3 (class (+ clueless 9.0)) ;=> java.lang.Double #4 #1 - Long by default #2 - Long can hold large values #3 - But when too large, the type promotes to BigInt #4 - Floating-point doubles are contagious !@%STYLE%@! {"css":"{\"css\": \"font-weight: bold;\"}","target":"[]"} !@%STYLE%@!
Although the type of the exception is a java.lang.ClassCastException, it was thrown by the compiler, which you’d see if you were to trace the stack using something like (for [e (.getStackTrace *e)] (.getClassName e)).[17] It’s perfectly acceptable (and even encouraged) to throw exceptions in your own macros, but it’s important to make a distinction between compile-time and runtime exceptions.
Clojure’s proxy mechanism is meant strictly for interoperability purposes. In section 9.3, we discuss how reify is intended to realize a single instance of a type, protocol, or interface—in other words, abstractions. But when dealing with Java libraries, you’re at times required to extend concrete classes, and it’s in this circumstance where proxy shines. Be aware that by using proxy, you bring a lot of Java’s semantics into your Clojure programs. Although extending concrete classes is seen often in Java, doing so in Clojure is considered poor design,[2] leading to fragility, and should therefore be restricted to those instances where interoperability demands it.