Age | Commit message (Collapse) | Author | |
---|---|---|---|
2014-01-28 | erts: Specs for Map BIFs | Björn-Egil Dahlberg | |
2014-01-28 | stdlib: Add Map module | Björn-Egil Dahlberg | |
The map type is set to term. | |||
2014-01-28 | erts: Remove erlang:size/1 test from map_SUITE | Björn-Egil Dahlberg | |
2014-01-28 | stdlib: Update erl_scan_SUITE for ':=' and '=>' tokens | Björn-Egil Dahlberg | |
2014-01-28 | stdlib: Deny variables as keys and disallow ':=' in map construction | Björn-Egil Dahlberg | |
In the current iteration of Maps we should deny *any* variables in Map keys. | |||
2014-01-28 | stdlib: Teach erl_eval Maps ':=' exact operator | Björn-Egil Dahlberg | |
2014-01-28 | erts: Update Maps erlang:phash2/1 tests | Björn-Egil Dahlberg | |
2014-01-28 | erts: erlang:phash2 should hash Maps independent of order | Björn-Egil Dahlberg | |
2014-01-28 | erts: Add Map tests for erlang:phash/2 | Björn-Egil Dahlberg | |
2014-01-28 | erts: Add Maps to erlang:phash/2 and erlang:hash/2 | Björn-Egil Dahlberg | |
The hashing a map in these functions uses the same strategy as the other terms. The exception being a prime number with size so we do not get erlang:phash(#{}) -> 1 which would be the same as erlang:phash({}) and erlang:phash(<<>>). Same argument for erlang:hash/1. | |||
2014-01-28 | erts: Add Map tests for hashing and external format | Björn-Egil Dahlberg | |
- Update map_SUITE with hash and encode tests - Update map_SUITE with external format decode tests - Update map_SUITE with map:to_list/1 and map:from_list/1 tests | |||
2014-01-28 | erts: Teach term_to_binary/1 and binary_to_term/1 Map encoding | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Rename map pattern to proper name | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Add Maps types to cerl | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Format stacktrace on error | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Teach Maps to beam_disasm | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Fix v3_core for map update syntax | Björn-Egil Dahlberg | |
Make map update expressions safe, i.e. (foo())#{ k1 := 1 } | |||
2014-01-28 | compiler: Fix get_map_element bug with allocate | Björn-Egil Dahlberg | |
The instruction get_map_element has a faillabel so you may not use the instruction within a allocate/deallocate block. | |||
2014-01-28 | compiler: Test Maps inlining | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Teach Maps understanding to inliner | Björn-Egil Dahlberg | |
2014-01-28 | erts: Fixup map instructions for halfword | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Implement different instructions for => and := | Björn Gustavsson | |
2014-01-28 | Pass the map pair operators through to the v3_codegen pass | Björn Gustavsson | |
2014-01-28 | sys_core_fold: Remove optimization that has become invalid | Björn Gustavsson | |
With the => and := operators for updating maps, this optimization is no longer valid. | |||
2014-01-28 | erts: Conform map_SUITE to extended syntax | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Implement support for exact Op in Maps | Björn-Egil Dahlberg | |
The syntax is handled upto v3_kernel where it is reduced to previous behaviour for construction and updates. Meaning, the ':=' operator is handled exactly as '=>' operator. | |||
2014-01-28 | Extend representation for maps in Core Erlang | Björn-Egil Dahlberg | |
2014-01-28 | Update erl_lint, erl_expand_records, sys_pre_expand for Maps | Björn-Egil Dahlberg | |
Update erlang lint and syntax expand for #{ K := V } | |||
2014-01-28 | stdlib: Fix erl_parse:parse_term/1 | Björn-Egil Dahlberg | |
Did not handle Maps. | |||
2014-01-28 | Extend erl_parse with two Op Map syntax | Björn-Egil Dahlberg | |
Example how to construct: #{ K1 => V1, K2 => V2 } How to update: M#{ K1 => V1, K2 := V2 } How to match: #{ K1 := V1, K2 := V2 } = M | |||
2014-01-28 | Teach erl_scan to recognize ':=' | Björn-Egil Dahlberg | |
2014-01-28 | erts: Add testsuite for Maps | Björn-Egil Dahlberg | |
2014-01-28 | erl_eval: Add functions to interpreter for maps | Björn-Egil Dahlberg | |
2014-01-28 | stdlib: Update printing to handle Maps | Björn-Egil Dahlberg | |
2014-01-28 | erts: Introduce more Maps BIFs | Björn-Egil Dahlberg | |
* map:remove/2 * map:keys/1 * map:values/1 * map:is_key/2 * map:update/3 - Equivalent to ':=' operator in #{ K := V } maps. * map:from_list/1 - map:from_list/1 takes any unsorted key/value list, [{K,V}], and produces a map. Duplicate keys are removed. The latest key is kept. * map:find/2 - Searches for a pair that *equals* input key. * map:merge/2 - Merge two maps to one map. | |||
2014-01-28 | erts: Add the type-testing guard BIF is_map/1 | Björn-Egil Dahlberg | |
To add a type-testing guard BIF, the following steps are needed: * The BIF itself is added to bif.tab (note that it should be declared using "ubif", not "bif"), and its implementation to erl_bif_op.c. * erl_internal must be modified in 3 places: The type test must be recognized as guard BIF, as a type test, and it must be auto-imported. * There must be an instruction that implements the same type test as the BIF (it will be used in guards). beam_utils:bif_to_test/3 must be updated to recognize the new guard BIF. | |||
2014-01-28 | erts: Add the size-testing guard BIF map_size/1 | Björn-Egil Dahlberg | |
2014-01-28 | erts: Add phash2 Map functionality | Björn-Egil Dahlberg | |
2014-01-28 | erts: Initial Map instructions, type and structure | Björn-Egil Dahlberg | |
2014-01-28 | erts: Maps beam-instruction definitions | Björn Gustavsson | |
2014-01-28 | compiler: Fix sorted keys in put_map instruction | Björn-Egil Dahlberg | |
All pairs in a Map needs to be in strict ascending key order. | |||
2014-01-28 | compiler: Fix multiple same keys | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Check for duplicate key literals in Map | Björn-Egil Dahlberg | |
If a literal key already is present in a Map update the latter should be used. Warn for previous duplicates in the Map. | |||
2014-01-28 | compiler: Handle literals, not just atoms, as keys in maps | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Fix no basic blocks for maps | Björn-Egil Dahlberg | |
2014-01-28 | compiler: Fix stack register reordering | Björn-Egil Dahlberg | |
Can now handle {list [reg()]} elements in instructions. | |||
2014-01-28 | Implement support for maps in the compiler | Björn Gustavsson | |
To make it possible to build the entire OTP system, also define dummys for the instructions in ops.tab. | |||
2014-01-28 | Introduce a representation for maps in Core Erlang | Björn Gustavsson | |
2014-01-28 | Update erl_lint, erl_expand_records, sys_pre_expand for maps | Björn Gustavsson | |
2014-01-28 | Extend erl_parse with the new map syntax | Björn-Egil Dahlberg | |
Example how to match or construct: #{ K1 => V1, K2 => V2 } How to update: M#{ K => V } |