Age | Commit message (Collapse) | Author |
|
|
|
|
|
* siri/make/default-outdir/ERL-438/OTP-14489:
[ct_make] Do not use the interactive tool 'c' from ct_make
Use current dir as default outdir for c:c/1,2
[make] Do not use the interactive tool 'c' from make
|
|
* dgud/stdlib/string-len-compat/OTP-14487:
Fix old length usage in string
|
|
In OTP-20, c:c/1,2 started using the directory of the source file as
default output directory. For backwards compatibility reasons this is
now reversed so the current directory is used instead.
|
|
Do not invoke the internal string:lenght/1 function
when the list length is wanted.
Fixes backwards compatibility for old string functions.
|
|
Add a few more tests to the proc_lib_SUITE.
|
|
The `error_logger_format_depth` variable is `unlimited` by default.
This can cause errors when logging crash reports using sasl logger,
because `io_lib:format("~P"...` does not support `unlimited` as a
depth parameter.
Use formatter string "~p" for unlimited depth.
A way to reproduce the error:
Start erl with sasl logger:
erl -boot start_sasl -sasl errlog_type error -sasl sasl_error_logger tty
Report arbitrary error:
error_logger:error_report(crash_report, [fake_crash_report, foo]).
|
|
|
|
|
|
This allows the use of ~ts/~tp/~tw in the formatting fun to
sys:handle_debug/4.
|
|
This allows the use of ~ts/~tp/~tw in calls to error_logger:format/2,
error_logger:error_msg/2 and error_logger:info_msg/2.
|
|
|
|
|
|
|
|
The ms_transform module, used by ets:fun2ms/1 and dbg:fun2ms,
evaluates constant arithmetic expressions. This is necessary since the
Erlang compiler, which normally evaluates constant expressions, does
not recognize the format generated by ms_transform.
|
|
* hasse/unicode_atoms/OTP-14285:
compiler: Handle (bad) Unicode parse transform module names
kernel: Improve handling of Unicode filenames
stdlib: Handle Unicode atoms in ms_transform
stdlib: Improve Unicode handling of the Erlang parser
stdlib: Handle unknown compiler options with Unicode
stdlib: Handle Unicode macro names
stdlib: Correct Unicode handling in escript
dialyzer: Improve handling of Unicode
parsetools: Improve handling of Unicode atoms
stdlib: Handle Unicode atoms when formatting stacktraces
stdlib: Add more checks of module names to the linter
stdlib: Handle Unicode atoms better in io_lib_format
stdlib: Handle Unicode atoms in c.erl
|
|
* dgud/stdlib/shell-find-src:
stdlib: Lookup src path in beam
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Unicode atoms are handled better by the Erlang code linter.
Module names are checked for character codes greater than 255. This
means that modules invoked after the linter can assume that module
names have only Latin-1 characters.
|
|
The field width calculation did not handle graphem clusters well.
|
|
Pull request 1459 (https://github.com/erlang/otp/pull/1459) points out
one situation where Unicode atoms are not handled well in c.erl. This
commit tries to fix all situations.
|
|
|
|
find and use source directive when searching for source file
|
|
|
|
This reverts commit eaf8ca41dfa4850437ad270d3897399c9358ced0.
|
|
|
|
erl_tar: Fix handling of date and time
|
|
Since aa0c4b0df7cdc, erl_tar would write the local time (instead of
the POSIX time) into the tar header for the archived files. When
extracting the tar file, the extracted file could be set to a future
time (depending on the time zone).
We could do a minimal fix, but this seems to be a good time
to rewrite the time handling to use the new features that
allow file info to be read and written in the POSIX time
format.
First reported here: https://github.com/erlang/rebar3/issues/1554
|
|
Return error tuple on unicode normalization functions
|
|
* hasse/stdlib/linter_check_dialyzer/OTP-14323:
stdlib: Warn for bad type variables of parameterized types
|
|
Prior to this patch, the normalization functions in the
unicode module would raise a function clause error for
non-utf8 binaries.
This patch changes it so it returns {error, SoFar, Invalid}
as characters_to_binary and characters_to_list does in
the unicode module.
Note string:next_codepoint/1 and string:next_grapheme had
to be changed accordingly and also return an error tuple.
|
|
The linter emits warnings about using '_' as type variable in
parameterized types.
|
|
* raimo/gen_statem-dev:
Fix documentation details
|
|
|
|
|
|
The postponed events, the user state and data, and the error
reason are all limited in error events (if the Kernel variable
error_logger_format_depth is set).
|
|
|
|
The size of the message queue and the dictionary is limited in
crash reports.
To avoid creating the potentially huge list of messages of the message
queue, messages are received (if the Kernel variable
error_logger_format_depth is set).
The tag 'message_queue_len' has been added to the crash report.
|
|
The state of the gen_server is limited in error events before exiting
(if the Kernel variable error_logger_format_depth is set).
An alternative is to let the error_logger limit all messages
(error_msg, format, warning_msg, info_msg), which would not limit
reports and also add a smallish overhead to event logging.
It is not decided if the alternative is to be implemented.
|
|
The term returned by io_lib:limit_term(Term, Depth) should return
the same string if substituted for Term in
io_lib:format("~P", [Term, Depth]) or io_lib:format("~W", [Term, Depth]).
|
|
proc_lib calls erlang:get_stacktrace/0 twice, which is unnecessary,
and potentially unsafe since there are calls to many functions
in between. Any of the calls could potentially cause and catch
an exception, invalidating the stacktrace.
Only call erlang:get_stacktrace/0 once, and pass the result to
the second place where it is needed.
|
|
It happens to work today, but it is potentially unsafe to call
io:format/2 before calling erlang:get_stacktrace/0. Make the
code safe by calling erlang:get_stacktrace/0 directly after
catching the exception.
|
|
Warn for potentially unsafe use of get_stacktrace/0
|
|
Prior to this patch, the stacktrace of an error or
exit in a callback would always be discarded in crash
reports. For example, an exit(crashed) in handle_call/3
would emit:
=CRASH REPORT==== 10-May-2017::14:15:50 ===
crasher:
initial call: gen_server_SUITE:init/1
pid: <0.201.0>
registered_name: []
exception exit: crashed
in function gen_server:terminate/8 (src/gen_server.erl, line 828)
Note that the stacktrace is pointing to the gen_server
internal terminate implementation that calls exit/1.
This patch uses erlang:raise/3 so the stacktrace is not
lost, allowing proc_lib to show the class, reason
and stacktrace coming from the user implementation
(in this case gen_server_SUITE):
=CRASH REPORT==== 10-May-2017::14:16:44 ===
crasher:
initial call: gen_server_SUITE:init/1
pid: <0.197.0>
registered_name: []
exception exit: crashed
in function gen_server_SUITE:handle_call/3 (gen_server_SUITE.erl, line 1529)
This change is completely backwards compatible as
using erlang:raise/3 will still emit the same exit
reason to any linked process and monitor as before.
|