matlab: support Octave 4.0.0
authorJoel Martin <github@martintribe.org>
Thu, 31 Dec 2015 19:43:55 +0000 (13:43 -0600)
committerJoel Martin <github@martintribe.org>
Thu, 31 Dec 2015 19:55:18 +0000 (13:55 -0600)
commit476996295578e4abb54bbf088a31e6120d6afd80
tree2f6f943d7a4066daaa5665bee27fe1dfd1b8540b
parent61fb553d025aaebe26d9c89c667aa59887ec7e99
matlab: support Octave 4.0.0

- Workarounds for Octave 4.0.0:
    - no containers.Map yet so use new Dict
      structure when running under Octave.
    - weird error when +FOO/ directory and FOO.m file both exist so
      rename types.m to type_utils.m
    - no getReport so implement custom stack printer
    - workaround weird issue that happens when a class initializer is
      called with the first argument of the same class as per
      Env(outer, ...). The class is not properly initialized. So for
      now, wrap the outer in a cell as Env({outer}, ...)
    - missing MException object types so when in Octave, use a global
      variable to store the error object.
    - missing native2unicode so just use 0xff character for keyword
      prefix.
    - workaround some function calling/passing differences. For
      example, the "@" anonymous function symbol does not seem to work
      for conveying an existing function but only for defininign a new
      one. E.g. this works:
          @(a,b) a+b
      but this doesn't
          @my_adder_fn.
      so just do this:
          @(a,b) my_adder_fn(a,b)

- Add Dockerfile with Octave

- Active Travis for matlab implementation using Octave
23 files changed:
.travis.yml
Makefile
matlab/+types/Function.m
matlab/+types/HashMap.m
matlab/+types/List.m
matlab/.dockerignore [new file with mode: 0644]
matlab/Dict.m [new file with mode: 0644]
matlab/Dockerfile [new file with mode: 0644]
matlab/Env.m
matlab/core.m
matlab/printer.m
matlab/reader.m
matlab/step1_read_print.m
matlab/step2_eval.m
matlab/step3_env.m
matlab/step4_if_fn_do.m
matlab/step5_tco.m
matlab/step6_file.m
matlab/step7_quote.m
matlab/step8_macros.m
matlab/step9_try.m
matlab/stepA_mal.m
matlab/type_utils.m [moved from matlab/types.m with 68% similarity]