Skip to content
Ambrose Bonnaire-Sergeant edited this page Jun 15, 2014 · 3 revisions

Small Tasks

E = easy M = medium H = hard

  • E Annotate more vars in clojure.core, and core Clojure namespaces.
  • E Test that all types of destructuring work
  • E Encode which types are safe to coerce to a primitive type, and vice versa
  • M Eliminate App type (TApp replaces all usages)
  • M Make RClass's first class type constructors (like Haskell type constructors)
    • eg. Seqable instead of (TFn [[x :variance :covariant]] (Seqable x))
  • E Devise better syntax for TFn's (type constructors/functions)
  • E Support pfn (polymorphic anonymous functions)
    • Very little to do IIRC, mostly all there.
  • M-H Figure out how to merge several CountRange's in an intersection
    • eg. (I (CountRange 1 5) (CountRange 2 4)) => (CountRange 2 4)
    • Useful in cases where you know (seq coll) and (<= 4 (count coll))
  • M-H Support metadata
    • Almost works, but with-meta should update metadata similar to assoc updates heterogeneous maps.
    • This means with-meta should be a primitive (no higher order usage)
    • The tricky case is where the target of with-meta already has metadata.
      • it's too inaccurate to put new metadata alongside the old one
      • need to "overwrite" all metadata types in the target.
    • Note: might be useful to formalise this first.
    • ie. (with-meta {} {:a 1}) => (I (IPersistentMap Nothing Nothing) (IMeta '{:a Number}))
  • M Generalise types in appropriate positions (like Typed Racket)
    • eg. (loop [a 1] ...), a should be generalised to AnyInteger or Number instead of the singleton 1.
  • E Ensure that annotations given to Java fields and methods are the same or more specific than the actual Java static type
    • Just need to compare actual type with assumed type via subtyping.
Clone this wiki locally