Age | Commit message (Collapse) | Author |
|
* fenollp/shell-expand-0arity-completely:
Shell: expand 0-arity functions all the way to closing parenthesis
OTP-11684
|
|
* josevalim/suppress-all-auto-imports:
Allow all auto imports to be suppressed at once
OTP-11682
|
|
* hsv/add_droplast_to_lists:
Added documentation of lists:droplast/1
Added tests for lists:droplast/1 to stdlib/lists_SUITE
stdlib/lists: Add function droplast/1 This functions drops the last element of a non-empty list.
|
|
* egil/maps/OTP-11616: (112 commits)
compiler: Add core compile test for maps
compiler: Fix core parse for Maps
compiler: Fixup #map_pair{} spec
erts: Strengthen map_SUITE tests
erts: Update maps_fold test to respect maps:fold/3
stdlib: Make maps:fold/3 order-independent
erts: Fixup enif_make_map_put on windows
erts: Update preloaded erts_internal.beam
hipe: Fixup update cerl pretty printer
erts: Add map construction to driver API
dialyzer: Add maps tests
dialyzer: Remove dead code
dialyzer: Reflect map_pair core changes in dialyzer
hipe: Update cerl pretty printer
compiler: Update inliner tests
compiler: Squash #c_map_pair_*{} to #c_map_pair{}
compiler: Squash #k_map_pair_*{} to #k_map_pair{}
preloaded: Fixup export cmp_term in erts_internal
erts: Change 'size' argument of enif_get_map_size from int* to size_t*
erts: Fix compile error for halfword emulator
...
|
|
* siri/appup_tests_17/OTP-11534:
Update sasl appup test to work for OTP release 17
Update stdlib appup test to work for OTP release 17
Update kernel appup test to work for OTP release 17
|
|
|
|
|
|
|
|
Reported-by: Michele Miron
|
|
re needs unicode option
|
|
`erl` has tab completion for modules' exported functions but expands
only up to the opening paren. This commit closes that opening paren
in case the function is of arity zero and there is no other function with
the same name. It browses the lists of matches (a 2nd time) for Arity,
on complete match and then decides what to append.
|
|
|
|
* mh/dict_orddict_is_empty/OTP-11353:
Update primary bootstrap
Add dict:is_empty/1 and orddict:is_empty/1
|
|
This patch introduces the no_auto_import attribute:
-compile(no_auto_import).
Useful for code generation tools that always use the
qualified function names and want to avoid the auto
imported functions clashing with local ones.
Implementation wise, we chose to have a special flag
'all' to avoid doing many set lookups when checking for
suppression.
|
|
|
|
* fenollp/treewide_remove_unexpected_0xff/OTP-11323:
Remove ^L characters hidden randomly in the code. Not those used in text files as delimiters.
|
|
|
|
|
|
dict:size/1 runs in constant time, but orddict:size/1 does not. With
this change, the two modules stay API compatible and gain a
constant-time function for checking whether a dictionary is empty.
|
|
files as delimiters.
While working on a tool that processes Erlang code and testing it against this repo,
I found out about those little sneaky 0xff. I thought it may be of help to other
people build such tools to remove non-conforming-to-standard characters.
|
|
Conflicts:
bootstrap/lib/stdlib/ebin/erl_lint.beam
|
|
When reporting a field redefinition in a record, erl_lint can forget
about some old unused variables.
f() -> X = 1, #r{a=foo,a=bar,a=qux}.
|
|
Variables used in the body of a try expression were marked as unsafe
*and* used, which makes no sense as an unsafe variable can't be used.
Function vtsubtract/2 is used to forget usage of such unsafe variables.
Reported-by: Paul Davis
|
|
When analyzing complex expressions (i.e. comprehensions, cases, tries,
ifs and receives), erl_lint does not forget about old unused variables
when returning the updated variable table. This causes a bug where old
unused variables are not recorded as such:
t(X, Y) ->
#r{a=[ K || K <- Y ],b=[ K || K <- Y ]}.
As erl_lint uses vtmerge_pat/2 to merge the results of the analysis of
the two list comprehensions, X is marked as used and the warning is not
emitted.
The function vtmerge_pat/2 is used instead of the similar vtmerge/2
which does not mark multiple occurrences of a variable as usage to
handle cases like the following one:
t(X, Y) ->
#r{a=A=X,b=A=Y}.
Other simpler expressions like conses, tuples and external fun
references do not correctly follow this behaviour, e.g. A is not marked
as used in the following code:
t(X, Y) ->
{A=X,A=Y}.
This commit fixes both issues and makes erl_lint not return old unused
variables in updated tables and makes all compound expressions use
vtmerge_pat/2.
Reported-by: Anders Ramsell
|
|
* maint:
Fix a Dets bug concerning traversal of tables
|
|
* hb/stdlib/dets_bugfix/OTP-11245:
Fix a Dets bug concerning traversal of tables
|
|
* maint:
Fix a bug in the linter regarding the 'fun M:F/A' construct
|
|
If the fun M:F/A construct was used erroneously the linter could
crash.
Thanks to Mikhail Sobolev for reporting the bug.
|
|
The bug was introduced in R16B.
Thanks to Manuel Durán Aguete.
|
|
|
|
Added to re:run and sets the corresponding fields in 'extra' struct
for the PCRE match engine. The result can be viewed by also
setting 'report_errors' when matching.
Some housekeeping was also done...
The offset option also did not properly check for offset's >= 0.
Change nomatch to BADARG when pre-compiled mp() is faked:
By constructing a 5-tuple with faked content but the right data types,
you could do a re:run which returned nomatch when in fact the mp() was
bad. The cheapest solution is to check the return from pcre_exec
better.
Remove unreachable code in erts_bif_re.c:
Replaced tests for things that logically simply
cannot happen with ASSERT.
|
|
|
|
Add notempty_atstart, no_start_optimize, ucp and
never_utf options from new PCRE version.
Use the new notempty_atstart in global matching.
Add inspect/2 function
Correctly handle dupnames when capturing a name, as
in Perl, get the leftmost matching occurence.
Also added all_names, to get all the names in the pattern
in alphabetical (name) order.
To be able to use this in global matching, an inspect
function that can dig out a namelist was added.
|
|
The relevant testoutputNN files were copied from the
PCRE distribution and some corrections were done to
run_pcre_tests.erl.
Also made test generator be more compiler friendly
The re_testoutput1_replacement_test and
re_testoutput1_split_test modules that are
generated by run_pcre_tests.erl (offline,
when a new version of PCRE is integrated in the VM)
took forever to compile, as one single huge function
contained all the tests. The autogenerated tests are now
split into ~50 functions, which reduces compile time to
approximately a third.
New automatic test suites are also generated from the
new testoutputNN files, and checked in.
|
|
* nox/illegal-bitstring-gen-pattern/OTP-11186:
Bootstrap added
Simplify v3_core's translation of bit string generators
Forbid unsized fields in patterns of binary generators
|
|
|
|
|
|
|
|
* pan/unicode_error_wrong_offset:
Fix faulty rest on error in unicode:characters_to_list
OTP-11080
|
|
It makes no sense to be able to do `<<...,Rest/binary>> <= ...` in a
comprehension. The related Dialyzer test is removed.
|
|
* maint:
stdlib: Fix ets_SUITE memory tests
|
|
* rickard-sverker/carrier-migration/OTP-10279:
stdlib: Fix ets_SUITE memory tests
|
|
Need to take 'mbcs_pool' into account.
|
|
Conflicts:
bootstrap/lib/stdlib/ebin/erl_pp.beam
|
|
* nox/erl_pp-callback/OTP-11140:
Update primary bootstrap
Support callback attributes in erl_pp
|
|
* maint:
erts: Document the +M<S>acul command line argument
erts: Carrier pool information in allocator information
erts: Use carrier pool for migration of carriers
erts: Implement test case for carrier pool
erts: Implement carrier pool
erts: Fix type errors in info functions
erts: Use Uint64 for call counts
erts: Fix failing testcase alloc_SUITE:rbtree
erts: Rename allocator aoffcbf to aoffcaobf
erts: Remove unnecessary flag arguments in allocators
erts: Remove SBMBC allocator
erts: Add test for add_mbc and remove_mbc callbacks
erts: Fix deallocation in removed carrier
erts: Change naive list to rb-tree of carriers in AOFF allocator
erts: Prepare aoff allocator for carrier migration
erts: Make carrier header sizes customizable
erts: Add "bestfit within carrier" for aoff allocator (aoffcbf)
Conflicts:
erts/preloaded/ebin/erlang.beam
|
|
|
|
|
|
|
|
In an email to erlang-questions, Bengt Kleberg wrote:
When I use c:ls/1 it reminds me so much of Unix "ls" that I
expect c:ls("filename") to work. The resulting error surprises
me every time (not the same day).
While teaching c:ls/1 to show non-directory files, update the
error handling to make use of the POSIX error codes from
file:list_dir/1 and file:format_error/1 (which had not been
invented when the c module was first implemented).
Suggested-by: Bengt Kleberg
Test-suite-by: Bengt Kleberg
|