1. 10 Dec, 2019 1 commit
    • JoJo's avatar
      Add `box` and `deref` · 9cfd60cb
      JoJo authored
      Heap allocation and pointer dereferencing. Required for recursive
      datatypes like lists.
  2. 09 Dec, 2019 1 commit
  3. 31 Oct, 2019 3 commits
    • JoJo's avatar
      Fix codegen of strings · 8cd053f1
      JoJo authored
      The type of the GlobalReference was wrong before, also we've removed
      TStr in favor of a datatype built on `TPtr Nat8`.
      Also, add a system for adding builtin datatypes that doesn't require
      any ugly hacks with dummy-positions and stuff.
    • JoJo's avatar
      Add type `TPtr` · 964845aa
      JoJo authored
      Useful for FFI, and will probably serve as a building block for GC /
      owned pointers later.
    • JoJo's avatar
      Add primitive types Nat,{Nat,Int}{8,16,32} · d93637f4
      JoJo authored
      Useful for FFI. No way of constructing them or casting between them
      yet (except for FFI).
  4. 30 Oct, 2019 2 commits
  5. 29 Oct, 2019 1 commit
    • JoJo's avatar
      Integrate Match with rest of compiler · 5807eef4
      JoJo authored
      Until now, the Match module was just kind of for "testing". It wasn't
      actually used in the rest of the compiler. This commit replaces my
      earlier, quite bad implementation of pattern matching to decision
      trees with Sestofts one.
      One major change made along the way was to how sub-matchees are
      accessed in the code-generator and interpreter. Previously, the
      decision tree was assumed to be structured such that we could simply
      extract sub-matchees and put them on a stack. As far as I understand
      it, that way is incompatible with Sestofts trees, as they can "skip"
      steps that are known to be irrefutable in context. As such, I have
      chosen to augment the `Access` type with some additional information,
      such that the value of a sub-matchee can simply be generated from the
      Access-path as needed, with memoization in the Selections module. See
  6. 25 Oct, 2019 1 commit
    • JoJo's avatar
      Impl pattern matching w decision trees & check for redundancy · e99a9cdb
      JoJo authored
      TODO: Check for exhaustiveness. TODO: Use the stratergy in that paper
      on "good decision trees" for picking columns instead of just building
      the tree left-to-right.
      Sorry for the big commit. This wasn't the easiest thing to
      implement. Took a while to understand how the whole thing would work,
      and had lots of small problems along the way. However, I'm mostly
      satistied with the result.
  7. 17 Oct, 2019 3 commits
  8. 12 Oct, 2019 5 commits
  9. 11 Oct, 2019 8 commits
  10. 10 Oct, 2019 5 commits
  11. 24 Aug, 2019 1 commit
  12. 23 Jun, 2019 4 commits
  13. 07 Jun, 2019 2 commits
  14. 04 Jun, 2019 1 commit
  15. 03 Jun, 2019 2 commits