Age | Commit message (Collapse) | Author |
|
Rationale
Today all compound data types except for maps can be deconstructed in guards.
For tuples we have `element/2` and for lists `hd/1` and `tl/1`. Maps are
completely opaque to guards. This means matching on maps can't be
abstracted into macros, which is often done with repetitive guards. It
also means that maps have to be always selected whole from ETS tables,
even when only one field would be enough, which creates a potential
efficiency issue.
This PR introduces an `erlang:map_get/2` guard-safe function that allows
extracting a map field in guard. An alternative to this function would be
to introduce the syntax for extracting a value from a map that was planned
in the original EEP: `Map#{Key}`.
Even outside of guards, since this function is a guard-BIF it is more
efficient than using `maps:get/2` (since it does not need to set up the
stack), and more convenient from pattern matching on the map (compare:
`#{key := Value} = Map, Value` to `map_get(key, Map)`).
Performance considerations
A common concern against adding this function is the notion that "guards
have to be fast" and ideally execute in constant time. While there are
some counterexamples (`length/1`), what is more important is the fact
that adding those functions does not change in any way the time
complexity of pattern matching - it's already possible to match on map
fields today directly in patterns - adding this ability to guards will
niether slow down or speed up the execution, it will only make certain
programs more convenient to write.
This first version is very naive and does not perform any optimizations.
|
|
|
|
Compile external fun expressions to literals
OTP-15003
|
|
* lukas/erts/tcp_send_return_closed/OTP-15001:
erts: tcp send should return {error,closed}
|
|
* lukas/ei/fix_tmo_test:
ei: Include stdlib.h to fix malloc usage in ei test
|
|
Split inets OTP-14113
|
|
* hans/ssh/dbg/OTP-14896:
ssh: New test suite ssh_dbg_SUITE for testing ssh_dbg
ssh: Use the new ssh_dbg module
ssh: New ssh_dbg module
ssh: Add ssh_connection_handler:alg/1 for test purposes
ssh: Unused fields #ssh.hkey and #ssh.kex removed
ssh: Simplify ssh_connection and ssh_connection_handler and their internal interfaces
|
|
|
|
|
|
|
|
|
|
|
|
interfaces
|
|
* hans/erl_docgen/datatype_title/OTP-15000:
erl_docgen: Add datatype-title tag to datatype tag
|
|
* ingela/ssl/DTLS-ECC:
ssl: Cleaner test setup to avoid unintentional test case dependencies
ssl: Correct ECC suite and DTLS ECC handling
|
|
|
|
Change-Id: I014b191da144c299d056eb155ed99ace710112b1
|
|
Change-Id: Ie0f52e82484462f8f7ec58c37ce16081af432797
|
|
Change-Id: Ie23a40e7159fe632cf5514ac617de17c5d5b5ce2
|
|
- Update ct_ftp to use the new FTP application.
Change-Id: I84223107361132ea3144cdf7421738c4bebffa40
|
|
Change-Id: I585ba5097632d460705257f03cb44adf8038f0be
|
|
Change-Id: I20d44e771577b19060fbba0b2e83f64909c60faa
|
|
Change-Id: Ie1e8a3fa458ee38a1c0b6a0f19e27e76c267688e
|
|
- Create directory structure
- Move code, tests, documentation from inets
- Add inets_tftp_wrapper
- Add tftp app to run-dialyzer script
Change-Id: I6a142ae66cecb9a1821cbf9ea6a45f66a836763d
|
|
Change-Id: I695066755f8394619d5f231a1060e467f2c82edf
|
|
Change-Id: Ie0a67ad22904ce9701f23bbf5573a182b4936790
|
|
- vsftpd =< 3.0.2 does not support ECDHE ciphers and the ssl application
removed ciphers with RSA key exchange from its default cipher list.
To allow interoperability with old versions of vsftpd, cipher suites
with RSA key exchange are appended to the default cipher list.
- Fix regex in ftp.appup.src
Change-Id: I53ce3b7f198ae95825eb0b5d39e94bdcebe78391
|
|
Change-Id: I5328d5feeac3b7279a8770e8fc27e2d9e8eed359
|
|
Change-Id: I9ec81e25d8135fa624554b5d011b2c554b3481d5
|
|
Change-Id: I4939a45cde292347975d8b870caeff15724046d2
|
|
Change-Id: Ifc3359b62e14b68320645f5d7c90bf1b9ccae016
|
|
Change-Id: I19bd2f1d4a35cbc5c233ebc8b2a9d52bbd37f047
|
|
Change-Id: Ie9cfc5902f3ec7f97df6f0764ff88b954139d87b
|
|
- Add appup file
- Update vsftpd configuration file with stronger cipher suites
- Remove unused functions from ftp_test_lib
- Improve certificate generation
Change-Id: I941e922d7532a3f2a05662aff621a175b630d3b5
|
|
Change-Id: I3d3e09bf1f3fd6109cfb2cdd91e69fcd9554a3c9
|
|
Change-Id: I38bbca9d3fb2d90869cfe468e444204514301c36
|
|
Change-Id: I72c564ea25d7cc41716229369459ae68d8706007
|
|
- Created initial directory structure for the FTP application.
- Updated inets Makefiles to not include FTP related modules.
- Remove ftp code from inets
- Implement backward compatibility layer for FTP
- Add inets_ftp_wrapper
- Fix failing TCs
Change-Id: I120ec5bdef0c3df4cee2d7880db2aec581505bc4
|
|
* sverker/driver-taints/OTP-14960:
erts: Include foreign static linked drivers in taints
erts: Fix harmless bug in macro IS_DRIVER_VERSION_GE
erts: Remove our own NIF modules from "taints"
erts: Refactor erts_static_nif_get_nif_init
erts: Add dynamic loaded drivers to list of "taints"
|
|
detected by valgrind. We cannot compare monitor
in state MON_FREE before it's initialized.
Still not really kosher to access 'state' without lock or atomic-op.
|
|
* john/erts/bwt-wt-dirty-schedulers/OTP-14959:
Add +sbwt/+swt analogues for dirty schedulers
|
|
* dgud/observer/fix-config-bug/OTP-14993:
Fix crash when config was wrong
|
|
* dgud/testcase-fixes:
debug info
add unicode opt env may contain unicode signs
Fix lexemes conversion
|
|
* dgud/revert-string-depr:
Revert "Deprecate old string functions"
|
|
|
|
When test handling was corrected it was obvious that DTLS ECC handling
was not compleated.
|
|
jhogberg/john/erts/any-term-as-seq_trace-label/OTP-14899
Lift the type restrictions on seq_trace token labels
|
|
That is, driver added with config option --enable-static-drivers.
|
|
harmless until we bump major version
|
|
bjorng/bjorn/compiler/fix-atom-leak/ERL-563/OTP-14968
Stop the compiler from overflowing the atom table
|