<feed xmlns='http://www.w3.org/2005/Atom'>
<title>otp.git/lib/stdlib/src, branch dgud-string-depr</title>
<subtitle>Mirror of Erlang/OTP repository.
</subtitle>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/'/>
<entry>
<title>Merge pull request #1801 from dtip/update-global-name-spec</title>
<updated>2018-05-08T08:10:53+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-05-08T08:10:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=80c5f0f27b84173b83aaf0ecfb8f839660b918a6'/>
<id>80c5f0f27b84173b83aaf0ecfb8f839660b918a6</id>
<content type='text'>
Update global name typespec</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Update global name typespec</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1802 from michalmuskala/map-is-key-bif</title>
<updated>2018-05-07T08:30:22+00:00</updated>
<author>
<name>Björn Gustavsson</name>
<email>bgustavsson@gmail.com</email>
</author>
<published>2018-05-07T08:30:22+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=7a19de1bf0eb863e0d0febf7e7e5e555c8628575'/>
<id>7a19de1bf0eb863e0d0febf7e7e5e555c8628575</id>
<content type='text'>
Introduce is_map_key/2 guard BIF

OTP-15037
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Introduce is_map_key/2 guard BIF

OTP-15037
</pre>
</div>
</content>
</entry>
<entry>
<title>Introduce is_map_key/2 guard BIF</title>
<updated>2018-04-29T15:03:43+00:00</updated>
<author>
<name>Michał Muskała</name>
<email>michal@muskala.eu</email>
</author>
<published>2018-04-27T10:40:07+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=5d0874a8f9fd617308d9024783db1e4e24268184'/>
<id>5d0874a8f9fd617308d9024783db1e4e24268184</id>
<content type='text'>
This complements the `map_get/2` guard BIF introduced in #1784.

Rationale.

`map_get/2` allows accessing map fields in guards, but it might be
problematic in more complex guard expressions, for example:

foo(X) when map_get(a, X) =:= 1 or is_list(X) -&gt; ...

The `is_list/1` part of the guard could never succeed since the
`map_get/2` guard would fail the whole guard expression. In this
situation, this could be solved by using `;` instead of `or` to separate
the guards, but it is not possible in every case.

To solve this situation, this PR proposes a `is_map_key/2` guard that
allows to check if a map has key inside a guard before trying to access
that key. When combined with `is_map/1` this allows to construct a
purely boolean guard expression testing a value of a key in a map.

Implementation.

Given the use case motivating the introduction of this function, the PR
contains compiler optimisations that produce optimial code for the
following guard expression:

foo(X) when is_map(X) and is_map_key(a, X) and map_get(a, X) =:= 1 -&gt; ok;
foo(_) -&gt; error.

Given all three tests share the failure label, the `is_map_key/2` and
`is_map/2` tests are optimised away.

As with `map_get/2` the `is_map_key/2` BIF is allowed in match specs.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This complements the `map_get/2` guard BIF introduced in #1784.

Rationale.

`map_get/2` allows accessing map fields in guards, but it might be
problematic in more complex guard expressions, for example:

foo(X) when map_get(a, X) =:= 1 or is_list(X) -&gt; ...

The `is_list/1` part of the guard could never succeed since the
`map_get/2` guard would fail the whole guard expression. In this
situation, this could be solved by using `;` instead of `or` to separate
the guards, but it is not possible in every case.

To solve this situation, this PR proposes a `is_map_key/2` guard that
allows to check if a map has key inside a guard before trying to access
that key. When combined with `is_map/1` this allows to construct a
purely boolean guard expression testing a value of a key in a map.

Implementation.

Given the use case motivating the introduction of this function, the PR
contains compiler optimisations that produce optimial code for the
following guard expression:

foo(X) when is_map(X) and is_map_key(a, X) and map_get(a, X) =:= 1 -&gt; ok;
foo(_) -&gt; error.

Given all three tests share the failure label, the `is_map_key/2` and
`is_map/2` tests are optimised away.

As with `map_get/2` the `is_map_key/2` BIF is allowed in match specs.
</pre>
</div>
</content>
</entry>
<entry>
<title>Update global name typespec</title>
<updated>2018-04-27T12:23:15+00:00</updated>
<author>
<name>Daniel Tipping</name>
<email>daniel.tipping@hotmail.co.uk</email>
</author>
<published>2018-04-27T12:23:15+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=10255ef1ff2b0d63c52d68a3c32de94c3c01cc0e'/>
<id>10255ef1ff2b0d63c52d68a3c32de94c3c01cc0e</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'siri/kernel/logger/OTP-13295'</title>
<updated>2018-04-27T08:13:17+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2018-04-27T08:13:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=56e88f364a32b471b03e2364c2eb84783642ad88'/>
<id>56e88f364a32b471b03e2364c2eb84783642ad88</id>
<content type='text'>
* siri/kernel/logger/OTP-13295:
  Add documentation of the built-in logger handlers
  Catch badarg in logger:get_format_depth/0
  Add chars_limit option to logger_formatter
  Don't kill logger process until all other processes are dead
  Set call timeout for logger_server to infinity
  Update primary bootstrap
  Test cuddle for logger
  Update cth_log_redirect to a logger handler
  Start using logger internally in kernel and stdlib
  Remove error_logger process and add logger process
  Add logger
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* siri/kernel/logger/OTP-13295:
  Add documentation of the built-in logger handlers
  Catch badarg in logger:get_format_depth/0
  Add chars_limit option to logger_formatter
  Don't kill logger process until all other processes are dead
  Set call timeout for logger_server to infinity
  Update primary bootstrap
  Test cuddle for logger
  Update cth_log_redirect to a logger handler
  Start using logger internally in kernel and stdlib
  Remove error_logger process and add logger process
  Add logger
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge branch 'hasse/stdlib/rfc3339_datetime/OTP-14764'</title>
<updated>2018-04-27T07:34:46+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-04-27T07:34:46+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=f58f8779c9c8cf623ebd117ccb3c41416069f2da'/>
<id>f58f8779c9c8cf623ebd117ccb3c41416069f2da</id>
<content type='text'>
* hasse/stdlib/rfc3339_datetime/OTP-14764:
  stdlib: Add RFC 3339 functions to module calendar
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
* hasse/stdlib/rfc3339_datetime/OTP-14764:
  stdlib: Add RFC 3339 functions to module calendar
</pre>
</div>
</content>
</entry>
<entry>
<title>Update appups in kernel, stdlib and sasl for OTP-21.0</title>
<updated>2018-04-26T14:24:48+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>siri@erlang.org</email>
</author>
<published>2017-10-23T12:22:35+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=c0e4e821312d792aef092803f0d8b70409a38263'/>
<id>c0e4e821312d792aef092803f0d8b70409a38263</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>[stdlib/sys]: install one debug function more times (#1781)</title>
<updated>2018-04-26T13:49:59+00:00</updated>
<author>
<name>Pouriya</name>
<email>pouriya.jahanbakhsh@gmail.com</email>
</author>
<published>2018-04-26T13:49:59+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=eefcc985530acbd5cc4c97b6e4f537492fd61622'/>
<id>eefcc985530acbd5cc4c97b6e4f537492fd61622</id>
<content type='text'>
Allow installing multiple instances of sys debug function

This commit solves a bug which allowed installing {Fun,State} as sys debug function even if Fun was already installed. This happened in the case when the current State of the debug fun was undefined.

Also, the new format {Id,Fun,State} of debug functions can be installed, allowing multiple instances of the same fun.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Allow installing multiple instances of sys debug function

This commit solves a bug which allowed installing {Fun,State} as sys debug function even if Fun was already installed. This happened in the case when the current State of the debug fun was undefined.

Also, the new format {Id,Fun,State} of debug functions can be installed, allowing multiple instances of the same fun.
</pre>
</div>
</content>
</entry>
<entry>
<title>Merge pull request #1759 from sunboshan/sys-fix</title>
<updated>2018-04-26T13:39:28+00:00</updated>
<author>
<name>Siri Hansen</name>
<email>erlangsiri@gmail.com</email>
</author>
<published>2018-04-26T13:39:28+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=f24a15640beef8acd832e4a3eaf20bbd3c16e38d'/>
<id>f24a15640beef8acd832e4a3eaf20bbd3c16e38d</id>
<content type='text'>
[stdlib/sys.erl] Fix sys module's debug statistics not including the out message count when using gen_server:call/2.

OTP-15047</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
[stdlib/sys.erl] Fix sys module's debug statistics not including the out message count when using gen_server:call/2.

OTP-15047</pre>
</div>
</content>
</entry>
<entry>
<title>stdlib: Add RFC 3339 functions to module calendar</title>
<updated>2018-04-26T13:30:20+00:00</updated>
<author>
<name>Hans Bolinder</name>
<email>hasse@erlang.org</email>
</author>
<published>2018-02-01T15:35:43+00:00</published>
<link rel='alternate' type='text/html' href='http://git.ninenines.eu/otp.git/commit/?id=c650e93aaac225559229968fbbf6dfd7ca5d0cf7'/>
<id>c650e93aaac225559229968fbbf6dfd7ca5d0cf7</id>
<content type='text'>
Functions for converting between RFC 3339 strings and system time
are added.

Options are lists, but we are considering using maps instead. If we
change, it will happen after Erlang/OTP 21.0-rc1 is released.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Functions for converting between RFC 3339 strings and system time
are added.

Options are lists, but we are considering using maps instead. If we
change, it will happen after Erlang/OTP 21.0-rc1 is released.
</pre>
</div>
</content>
</entry>
</feed>
