文件名称:bitfield.erl:erlangelixir的简单位域
文件大小:4KB
文件格式:ZIP
更新时间:2024-06-08 11:02:11
Elixir
位域 erlang / elixir的简单位域 用法 埃尔朗 % % Create a list of fields Enum = [<< " name " >>, << " age " >>, << " email " >>, << " address " >>, << " friends " >>]. % % Fields to be enabled Enabled = [<< " name " >>, << " address " >>]. Packed = bitfield : pack ( Enabled , Enum ). % % => <<144>> Unpacked = bitfield : unpack ( Packed , Enum ). % % => [<<"name">>, <<"address">>] 长生不老药 ## Create a list of fi
【文件预览】:
bitfield.erl-master
----.travis.yml(39B)
----mix.exs(715B)
----test()
--------test_helper.exs(14B)
--------bitfield_test.exs(485B)
----rebar.config(58B)
----src()
--------bitfield.erl(969B)
--------bitfield.app.src(189B)
----.gitignore(62B)
----lib()
--------bitfield.ex(124B)
----README.md(826B)