From 93eb82e1bf6d2f2a6b3b0adb85f4ab93cbb766a9 Mon Sep 17 00:00:00 2001 From: Eduardo Julian Date: Mon, 14 Mar 2022 03:33:01 -0400 Subject: De-sigil-ification: @ --- stdlib/source/documentation/lux.lux | 40 ++++++++++++++++++------------------- 1 file changed, 20 insertions(+), 20 deletions(-) (limited to 'stdlib/source/documentation/lux.lux') diff --git a/stdlib/source/documentation/lux.lux b/stdlib/source/documentation/lux.lux index 8fcfe64d9..64241e5ff 100644 --- a/stdlib/source/documentation/lux.lux +++ b/stdlib/source/documentation/lux.lux @@ -552,13 +552,13 @@ (odd? num) "WHEN odd" "ELSE")]) -(documentation: /.value@ +(documentation: /.the "Accesses the value of a record at a given tag." - [(value@ #field my_record)] + [(the #field my_record)] ["Can also work with multiple levels of nesting." - (value@ [#foo #bar #baz] my_record)] + (the [#foo #bar #baz] my_record)] ["And, if only the slot/path is given, generates an accessor function." - (let [getter (value@ [#foo #bar #baz])] + (let [getter (the [#foo #bar #baz])] (getter my_record))]) (documentation: /.open: @@ -611,26 +611,26 @@ ["Also allows using that value as a function." (# codec encoded +123)]) -(documentation: /.with@ +(documentation: /.has "Sets the value of a record at a given tag." - [(with@ #name "Lux" lang)] + [(has #name "Lux" lang)] ["Can also work with multiple levels of nesting." - (with@ [#foo #bar #baz] value my_record)] + (has [#foo #bar #baz] value my_record)] ["And, if only the slot/path and (optionally) the value are given, generates a mutator function." - (let [setter (with@ [#foo #bar #baz] value)] + (let [setter (has [#foo #bar #baz] value)] (setter my_record)) - (let [setter (with@ [#foo #bar #baz])] + (let [setter (has [#foo #bar #baz])] (setter value my_record))]) -(documentation: /.revised@ +(documentation: /.revised "Modifies the value of a record at a given tag, based on some function." - [(revised@ #age ++ person)] + [(revised #age ++ person)] ["Can also work with multiple levels of nesting." - (revised@ [#foo #bar #baz] func my_record)] + (revised [#foo #bar #baz] func my_record)] ["And, if only the slot/path and (optionally) the value are given, generates a mutator function." - (let [updater (revised@ [#foo #bar #baz] func)] + (let [updater (revised [#foo #bar #baz] func)] (updater my_record)) - (let [updater (revised@ [#foo #bar #baz])] + (let [updater (revised [#foo #bar #baz])] (updater func my_record))]) (documentation: /.^template @@ -786,9 +786,9 @@ (same? +5 (+ +2 +3))]) -(documentation: /.^@ +(documentation: /.^let "Allows you to simultaneously bind and de-structure a value." - [(def: (hash (^@ set [member_hash _])) + [(def: (hash (^let set [member_hash _])) (list#mix (function (_ elem acc) (+ acc (# member_hash hash elem))) @@ -981,14 +981,14 @@ ..module_separator ..^open ..cond - ..value@ + ..the ..open: ..|>> ..<<| ..using ..# - ..with@ - ..revised@ + ..has + ..revised ..^template ..++ ..-- @@ -999,7 +999,7 @@ ..symbol ..:parameter ..same? - ..^@ + ..^let ..^|> ..:expected ..undefined -- cgit v1.2.3