Note that there are some explanatory texts on larger screens.

plurals
  1. USVladimir Matveev
    primarykey
    data
    text
    plurals
    1. COClojure compiler is able to extract some information about types from the source code. It is possible to write completely dynamic system using reflection everywhere, but the code produced by such compiler will be very slow. Clojure does a good job in finding expression types, and you can use type hints to direct it if needed, but it is impossible to make Clojure use strong type system without turning it into completely different language.
      singulars
    2. COOTOH, weak type systems like in Python usually do not provide any information about expressions. The exact type of the expression become known only when this expression is evaluated. Such systems are much more easier to implement and program with, but they do not have strong guarantees, and the languages based on such systems are subjects to runtime errors, when some operation is applied to a value of incompatible type.
      singulars
    3. COBy "strength" of the type system I understand the amount of metainformation about variables and expressions which compiler is able to get. In those type systems which are formal theories, like System F or even Calculus of Constructions (Agda2, Coq), the guarantees about types are so strong that it is possible to prove that the value of given expression will always be in the boundaries of statically known range. This essentially eliminates all but the logical errors, and even some logical errors too, given that the program typechecks and compiles.
      singulars
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload