Commit Graph

26 Commits

Author SHA1 Message Date
Jeremie Dimino 0c6edde131 Add a user context to Of_sexp.t
Signed-off-by: Jeremie Dimino <jeremie@dimino.org>
2018-06-19 16:26:00 +01:00
Jeremie Dimino 30d20d6143 Use a single S-expression parser monad
Signed-off-by: Jeremie Dimino <jeremie@dimino.org>
2018-06-19 11:29:27 +01:00
Rudi Grinberg 065e2bb26f Make Sexp.Of_sexp.t abstract
Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
2018-06-19 11:29:27 +01:00
Jérémie Dimino 4d8ca489be
Add support for environment & build profiles (#419) 2018-05-04 16:49:25 +01:00
Rudi Grinberg 24041593da Move Code_error to Stdune.Exn
This exception is useful outside of jbuilder
2018-04-23 14:04:15 +07:00
Rudi Grinberg 98b2ea795c Move String_map to stdune 2018-04-23 12:43:20 +07:00
Rudi Grinberg 530dbfeb81 Move String_set to stdune 2018-04-23 12:08:09 +07:00
Rudi Grinberg 25158fc702 Share Ordered_set_lang.Make(String)(String) 2018-03-15 14:25:04 +08:00
Rudi Grinberg c8355b454c Generalize Ordered_set_lang to return a custom map
This simplifes all the conversion from and to Module.Name.Map.t
2018-03-06 18:45:38 +07:00
Rudi Grinberg 5ecf354127 Add a sub-system for inline tests (#547)
To support frameworks such as ppx_inline_test, ppx_expect and qtest
2018-02-27 19:06:12 +00:00
Jérémie Dimino 3fd3eb8a12
Split src/import.ml into a new library src/stdune (#548)
- make sure type t always come first
- Map.map, Map.fold, ... never pass the key to the callback while Map.mapi, Map.foldi, ... do
- removed the ~key and ~data labels, I find them useless and annoying
- Set.elements --> Set.to_list
- Map.bindings --> Map.to_list
- Map.of_alist --> Map.of_list
- added Ordering.t for comparison functions
- renamed Inl/Inr to Left/Right. The latter seems clearer
- moved List.longest to String.longest
- added a Pp module with a nicer API than Format
2018-02-25 16:35:25 +00:00
Christophe Troestler fbafb3d47a Make Atom.t private and consequences (#524) 2018-02-24 23:33:26 +00:00
Christophe Troestler 67c9363c7d Use more precise combinators "atom" and "quoted_string" 2018-02-15 00:45:06 +01:00
Christophe Troestler 73f529ae82 Rename String to Quoted_string 2018-02-15 00:43:08 +01:00
Christophe Troestler c27cb3541e Let the parser distinguish quoted strings
Fixes https://github.com/ocaml/dune/issues/408
2018-02-15 00:43:08 +01:00
Jérémie Dimino b3838284c6
Better support for mli/rei only modules (#489) 2018-02-08 10:12:46 +00:00
Jérémie Dimino 80c0bfc879
Split calls to ocamldep (#486)
Instead of doing a single call to ocamldep, do one per file. This is
needed to support "menhir --infer".

This should also make compilation go further when there are files with
syntax errors.
2018-02-06 11:48:04 +00:00
Rudi Grinberg 7c6f3e6dd6 support ${..} in :include 2017-10-10 15:53:39 -04:00
David Allsopp 2d100b1150 Improve error handling for (:include )
The form (:include $(SCOPE_ROOT)\foo) requires quoting, but the error
message was cryptic ("Error: undefined symbol include").

Signed-off-by: David Allsopp <david.allsopp@metastack.com>
2017-08-25 11:12:15 +01:00
David Allsopp 3a64432d04 Expand variables in flags
Extend Ordered_set_lang.Unexpanded.expand to include a mapping function
for the S-expression for each atom. The previous behaviour can be
achieved with ~f:Sexp.Of_sexp.string, but this allows the S-expression
to be parsed using String_with_vars.t, thus allowing variable expansion.
2017-08-03 17:28:32 +01:00
David Allsopp 83bba5af61 Use an AST for Ordered_set_lang 2017-08-03 17:28:32 +01:00
Jérémie Dimino c6b2169037 Refactor S-expression parsing 2017-02-25 18:03:56 +00:00
Jeremie Dimino e75f0e4455 Interpret extra_disabled_warnings 2017-02-23 10:43:51 +00:00
Jeremie Dimino 9e4a83bf48 add support for c_library_flags 2017-01-06 17:18:36 +00:00
Jeremie Dimino 11c61b3234 114.20+69 2016-12-23 15:32:23 +00:00
Jeremie Dimino cdcd7e907f 114.20+69 2016-12-02 13:54:32 +00:00