Map -spec in erlang -


i'm looking use new erlang maps in project, want make sure -spec do. question is, what's syntax this? there there records can specify field types? or use map() (and correct type spec?)

yes, map() 1 way specify map type. #{}, map() means map of size. can specify #{ type => type } 1 or more type => type pairs, described in erlang types , function specifications page. also, have @ can_pkt() type in source code maps1 test in erlang source code, specifies record-like map type.


Comments

Popular posts from this blog

commonjs - How to write a typescript definition file for a node module that exports a function? -

openid - Okta: Failed to get authorization code through API call -

ios - Change Storyboard View using Seague -