From bc38beafd07b7ae6106a2fffda82084a08af7f06 Mon Sep 17 00:00:00 2001 From: Ziv Scully Date: Sun, 19 Jul 2015 19:03:11 -0700 Subject: Rename C functions and remove functors nested inside modules. --- src/option_key_fn.sml | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 src/option_key_fn.sml (limited to 'src/option_key_fn.sml') diff --git a/src/option_key_fn.sml b/src/option_key_fn.sml new file mode 100644 index 00000000..ba636d4e --- /dev/null +++ b/src/option_key_fn.sml @@ -0,0 +1,11 @@ +functor OptionKeyFn(K : ORD_KEY) : ORD_KEY = struct + +type ord_key = K.ord_key option + +val compare = + fn (NONE, NONE) => EQUAL + | (NONE, _) => LESS + | (_, NONE) => GREATER + | (SOME x, SOME y) => K.compare (x, y) + +end -- cgit v1.2.3