Re: The feature to find the value inside the nested map.
Ivan Uemlianin <[email protected]>
| Newsgroups | gmane.comp.lang.erlang.general |
|---|---|
| Message-ID | <[email protected]> |
Agree. Haskellers call them lenses.
There was a discussion about them here a few years ago:
http://erlang.org/pipermail/erlang-questions/2015-November/086879.html
And there have been a few implementation attempts:
2020 https://github.com/slepher/lenses
2015 https://www.cs.otago.ac.nz/staffpriv/ok/lens.erl
2012 https://github.com/jlouis/erl-lenses
Best wishes
Ivan
On 16/06/2021 03:04, 瀬川昂弘 wrote:
> Assuming,
> Map = #{a => b,c => #{1 => 2,3 => 4,5 => #{x => y}}}.
>
> Expected:
> maps:new_find_fun(Key = 5, Map) = {ok,#{x => y}}.
>
> It's useful there is the above feature, in my guess.
>
> --
> Takahiro Segawa.
> E-mail:[email protected]
> <mailto:[email protected]>
--
============================================================
Ivan A. Uemlianin PhD
Llaisdy
Ymchwil a Datblygu Technoleg Lleferydd
Speech Technology Research and Development
[email protected]
@llaisdy
llaisdy.wordpress.com
github.com/llaisdy
www.linkedin.com/in/ivanuemlianin
festina lente
============================================================