From 34e310622bdeb1d0588c0664c0e78cbaa84f837c Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Wed, 2 Dec 2020 06:42:20 -0400 Subject: Re-named "::" and ":::" macros to "\" and "\\", to be consistent with the convention that only macros that deal with types may start with a colon. --- stdlib/source/lux.lux | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'stdlib/source/lux.lux') diff --git a/stdlib/source/lux.lux b/stdlib/source/lux.lux index 639d9ab09..a5ee64cab 100644 --- a/stdlib/source/lux.lux +++ b/stdlib/source/lux.lux @@ -4375,9 +4375,9 @@ "(open: ''i:.'' number)" __paragraph "## Will generate:" ..new-line - "(def: i:+ (:: number +))" ..new-line - "(def: i:- (:: number -))" ..new-line - "(def: i:* (:: number *))" ..new-line + "(def: i:+ (\ number +))" ..new-line + "(def: i:- (\ number -))" ..new-line + "(def: i:* (\ number *))" ..new-line "..."))} (case tokens (^ (list [_ (#Text alias)] struct)) @@ -4586,13 +4586,13 @@ (~ =imports)))]] (wrap (#Cons =module =refers)))) -(macro: #export (:: tokens) +(macro: #export (\ tokens) {#.doc (text$ ($_ "lux text concat" "## Allows accessing the value of a structure's member." ..new-line - "(:: codec encode)" + "(\ codec encode)" __paragraph "## Also allows using that value as a function." ..new-line - "(:: codec encode +123)"))} + "(\ codec encode +123)"))} (case tokens (^ (list struct [_ (#Identifier member)])) (return (list (` (let [(^open ".") (~ struct)] (~ (identifier$ member)))))) @@ -5172,8 +5172,8 @@ (with-expansions [ (template [ ] [(compare ) - (compare (:: Code/encode encode )) - (compare #1 (:: equivalence = ))] + (compare (\ Code/encode encode )) + (compare #1 (\ equivalence = ))] [(bit #1) "#1" [_ (#.Bit #1)]] [(bit #0) "#0" [_ (#.Bit #0)]] @@ -5281,7 +5281,7 @@ (wrap [meta (#Record =pairs)])) _ - (:: meta-monad return token) + (\ meta-monad return token) )) (macro: #export (static tokens) @@ -5468,7 +5468,7 @@ (macro: #export (^@ tokens) {#.doc (doc "Allows you to simultaneously bind and de-structure a value." (def: (hash (^@ set [Hash _])) - (list\fold (function (_ elem acc) (+ (:: Hash hash elem) acc)) + (list\fold (function (_ elem acc) (+ (\ Hash hash elem) acc)) 0 (to-list set))))} (case tokens -- cgit v1.2.3