From 2e86fefe6f15877e8c46a45411a9cbd04b26e2e3 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Tue, 5 Dec 2017 22:55:11 -0400 Subject: - WIP: Caching. --- new-luxc/source/luxc/module/descriptor/common.lux | 37 ----------------------- 1 file changed, 37 deletions(-) delete mode 100644 new-luxc/source/luxc/module/descriptor/common.lux (limited to 'new-luxc/source/luxc/module/descriptor/common.lux') diff --git a/new-luxc/source/luxc/module/descriptor/common.lux b/new-luxc/source/luxc/module/descriptor/common.lux deleted file mode 100644 index b123fe852..000000000 --- a/new-luxc/source/luxc/module/descriptor/common.lux +++ /dev/null @@ -1,37 +0,0 @@ -(.module: - lux - (lux (data [text] - (text format - ["l" lexer "l/" Monad]) - (coll [list "L/" Functor])))) - -(type: #export Signal Text) - -(do-template [ ] - [(def: #export Signal )] - - [cons-signal "\u0005"] - [nil-signal "\u0006"] - [stop-signal "\u0007"] - ) - -(do-template [ ] - [(def: #export Signal )] - - [ident-separator "."] - ) - -(def: #export (encode-list encode-elem types) - (All [a] (-> (-> a Text) (List a) Text)) - (format (|> (L/map encode-elem types) - (text.join-with cons-signal)) - nil-signal)) - -(def: #export (decode-list decode-elem) - (All [a] (-> (l.Lexer a) (l.Lexer (List a)))) - (l.alt (<| (l.after (l.text nil-signal)) - (l/wrap [])) - (<| (l.seq decode-elem) - (l.after (l.text cons-signal)) - (decode-list decode-elem)))) - -- cgit v1.2.3