aboutsummaryrefslogtreecommitdiffstats
path: root/lib/stdlib
AgeCommit message (Collapse)Author
2011-12-09Update copyright yearsBjörn-Egil Dahlberg
2011-12-09Merge branch 'bjorn/inviso/deprecate/OTP-9798'Björn Gustavsson
* bjorn/inviso/deprecate/OTP-9798: Deprecate the inviso application
2011-12-08Deprecate the inviso applicationBjörn Gustavsson
2011-12-08Change supervisor_SUITE to pure common test styleSiri Hansen
Also, some minor debug help is added to a test case which fails every now and then.
2011-12-05Fix typos in io_protocol.xmlTuncer Ayaz
2011-12-05Fix typos in tar_SUITETuncer Ayaz
2011-11-30Remove dependency on R12 from a qlc test caseHans Bolinder
The new file lib/stdlib/test/qlc_SUITE_data/join_info_compat.erl was created on an R12B node.
2011-11-30Merge branch 'siri/stdlib/dialyzer-supervisor/OTP-9741'Siri Hansen
* siri/stdlib/dialyzer-supervisor/OTP-9741: Add test for upgrade of supervisor Fix dialyzer warnings in supervisor
2011-11-30Merge branch 'bjorn/deprecate-tuple-funs/OTP-9649'Björn Gustavsson
* bjorn/deprecate-tuple-funs/OTP-9649: erts: Warn the first time a tuple fun is called otp_mibs: Eliminate use of tuple fun os_mon: Eliminate use of tuple fun asn1: Eliminate use of tuple fun parsetools: Eliminate use of tuple fun mnesia tests: Eliminate use of tuple fun snmp: Eliminate use of tuple fun wrap_log_reader_SUITE: Eliminate use of tuple fun big_SUITE: Eliminate use of tuple fun file_SUITE: Eliminate use of tuple fun fprof: Eliminate use of tuple fun xref_compiler: Eliminate use of tuple fun shell: Eliminate use of tuple funs erl_eval: Eliminate use of tuple funs user_sup: Eliminate use of tuple fun
2011-11-30Merge branch 'siri/stdlib/dialyzer-log_mf_h/OTP-9754'Siri Hansen
* siri/stdlib/dialyzer-log_mf_h/OTP-9754: Fix dialyzer warning about gen_event callback init/1 in log_mf_h
2011-11-30Fix dialyzer warning about gen_event callback init/1 in log_mf_hSiri Hansen
The warning is about log_mf_h having a different spec for gen_event callback init/1 than defined in gen_event.erl. log_mf_h allows return value {error,Reason}, while gen_even only specifies successful return values. This commit add {error,Reason} as a valid return value to the gen_event callback, since this is handled by the code.
2011-11-29Fix dialyzer warnings in supervisorSiri Hansen
Dialyzer complained over a mismatch between the callback spec of Mod:code_change in gen_server and the spec of supervisor:code_change (which is the implementation of a gen_server Mod:code_change). This commit changes the callback spec to allow {error,Reason} as return value. Also, release_handler is updated to handle this return value.
2011-11-29shell: Eliminate use of tuple funsBjörn Gustavsson
2011-11-29erl_eval: Eliminate use of tuple funsBjörn Gustavsson
2011-11-28otp_internal: Deprecate ssl:pid/1Björn Gustavsson
2011-11-28Merge branch 'bjorn/compiler/options/OTP-9752'Björn Gustavsson
* bjorn/compiler/options/OTP-9752: filename documentation: Recommend against using filename:find_src/1,2 Teach filename:find_src/1,2 to handle slim or stripped BEAM files filename: Eliminate failing call to Mod:module_info(source_file) filename.erl:filter_options/1: Remove handling of dead options compiler: Don't include {cwd,_} in module_info(compile) compiler: Don't include source code options in module_info(compile) hipe: Teach hipe to handle slim or stripped BEAM files
2011-11-28stdlib: Fix typo in unicode_usage.xmlRaimo Niskanen
Reported by Uwe Dauernheim.
2011-11-28Merge branch 'bjorn/fix-failing-tests'Björn Gustavsson
* bjorn/fix-failing-tests: erlc_SUITE:arg_overflow/1: Lower number of options for MacOS X Lion tar_SUITE: Don't do symlink tests on Windows erlc_SUITE: Fix failing compile_mib/1 test case
2011-11-28Merge branch 'bjorn/major-release-cleanups'Björn Gustavsson
* bjorn/major-release-cleanups: observer tests: Test compatibility with R13, not R12 emulator tests: Test compatibility with R13, not R12 Teach the compiler the 'r14' option erl_lint: The types introduced in R12B-5 are no longer "newly introduced" otp_internal: Stop warning for functions removed in R12 or earlier Conflicts: lib/stdlib/src/otp_internal.erl
2011-11-24filename documentation: Recommend against using filename:find_src/1,2Björn Gustavsson
2011-11-24Teach filename:find_src/1,2 to handle slim or stripped BEAM filesBjörn Gustavsson
filename:find_src/1,2 will crash when asked to find the source corresponding to a BEAM with no compilation options. A BEAM file can be missing compilation options if it has been stripped using beam_lib:strip/1 or compiled using the undocumented 'slim' option. Why this matters: If ERL_COMPILE_OPTIONS is set to +slim before building Erlang/OTP, there will be a crash in 'igor' during the building of the public_key application. ('igor' merges several source code files, and uses filename:find_src/1,2 to find the source code.) Change filename:find_src/1,2 to return an empty option list if there are no options in the BEAM file. Noticed-by: Per Hedeland
2011-11-24filename: Eliminate failing call to Mod:module_info(source_file)Björn Gustavsson
Mod:module_info(source_file) is no longer supported (and have not been for a long time), so calling it will always fail.
2011-11-24filename.erl:filter_options/1: Remove handling of dead optionsBjörn Gustavsson
The 'trace' and 'fast' options are no longer supported. While at it, correct the comment about option filtering.
2011-11-24Merge branch 'bjorn/remove-regexp-module/OTP-9737'Björn Gustavsson
* bjorn/remove-regexp-module/OTP-9737: stdlib: Remove the deprecated regexp module
2011-11-24erl_lint: The types introduced in R12B-5 are no longer "newly introduced"Björn Gustavsson
When a new built-in type is introduced, type definitions with the same name will still be allowed for "a while".
2011-11-24otp_internal: Stop warning for functions removed in R12 or earlierBjörn Gustavsson
When a deprecated function has been removed, the compiler will issue a warning if it sees a call to it, even for functions that were removed as far back as the R9 release. Since the otp_internal module grows when new deprecated functions are added, let's reduce its size somewhat by removing information about functions that were removed in the R12 release or earlier.
2011-11-23tar_SUITE: Don't do symlink tests on WindowsBjörn Gustavsson
2011-11-22Revert "Update version numbers for pre-release of R15"Björn-Egil Dahlberg
This reverts commit e21ff9b0b69219ab3853be7e80813156113152b7.
2011-11-22Update version numbers for pre-release of R15OTP_R15ABjörn Gustavsson
2011-11-18Merge branch 'pan/binary_match_scope/OTP-9701'Patrik Nyblom
* pan/binary_match_scope/OTP-9701: Remove remaining gcc 4.6 assigned-but-not-used warnings from erts Remove GCC 4.6 set-but-not-used warning from erl_bif_binary Make binary:match with scope return correct values
2011-11-18Merge branch 'sverk/hipe-without-fpe/OTP-9724'Sverker Eriksson
* sverk/hipe-without-fpe/OTP-9724: otp_build: Disable FPE by default on Linux stdlib: Make sure qlc_SUITE:otp_6964 restores backtrace_depth erts: Add test for inf/NaN intermediate float results hipe,erts: Allow hipe without floating point exceptions hipe: Fix bug in hipe_rtl_lcm:calc_killed_expr_bb erts: Rename macros used by float instructions without FPE
2011-11-18Merge branch 'siri/sasl/upgrade-erts/OTP-9438'Siri Hansen
* siri/sasl/upgrade-erts/OTP-9438: Fix bug in erts upgrade on windows Add release vsn info to erts_vsn_changed warning Check for sasl application in systools:make_script and make_relup Add syntax check of relup to check_install_release and install_release Add documentation for upgrade from pre R15 to post R15 sasl Handle upgrade from pre R15 to post R15 sasl Step version of sasl to 2.2 for R15 Document upgrade instructions restart_new_emulator and restart_emulator Wait for two restarts in upgrade_restart test Add restart_new_emulator instruction to kernel, stdlib and sasl appups Distinguish restart_new_emulator from restart_emulator in upgrade instructions Upgrade erts: merge sys.config for tmp release instead of using old Allow regexp for version in .appup Restart emulator before running upgrade script when erts is upgraded Conflicts: lib/sasl/src/release_handler.erl lib/sasl/test/release_handler_SUITE.erl
2011-11-17Add restart_new_emulator instruction to kernel, stdlib and sasl appupsSiri Hansen
The appup files for kernel, stdlib and sasl did not contain any UpFromVsn and DownToVsn. This means that it was not possible to create a relup file with systool:make_relup if any of these applications had changed. This commit adds entries in the appup files for a maximum of two major releases back - all with only one upgrade instruction: restart_new_emulator. The point is to allow relups to be generated, but ensure that no soft upgrade is done for these three applications - i.e. they will always cause a restart of the emulator prior to all other upgrade instructions from other applications. Test cases (appup_test) are added to kernel_SUITE, stdlib_SUITE and sasl_SUITE. These all check that expected versions are matched in the appups, and illegal versions (older than two major releases, or in any other way illegal) do not match. The test is written in a general way where it is assumed that the version of these applications are stepped according the the rule that major releases step the second number, maintenance releases step the third number and patches step the fourth number.
2011-11-17stdlib: Make sure qlc_SUITE:otp_6964 restores backtrace_depthSverker Eriksson
2011-11-16Make binary:match with scope return correct valuesPatrik Nyblom
2011-11-16Merge branch 'siri/stdlib/improve-doc-restart-strategy/OTP-9381'Siri Hansen
* siri/stdlib/improve-doc-restart-strategy/OTP-9381: Improve documentation on supervisor restart strategy
2011-11-16Improve documentation on supervisor restart strategySiri Hansen
2011-11-14Remove the undocumented function global:safe_whereis_name/1Hans Bolinder
2011-11-14Remove all use of global:safe_whereis_name/1Hans Bolinder
Calls to global:whereis_name/1 have been substituted for calls to global:safe_whereis_name/1 since the latter is not safe at all. The reason for not doing this earlier is that setting a global lock masked out a bug concerning the restart of supervised children. The bug has now been fixed by a modification of global:whereis_name/1. (Thanks to Ulf Wiger for code contribution.)
2011-11-14Fix a minor race in gen_fsmHans Bolinder
Fixed a minor race conditions in gen_fsm:start*: if one of these functions returned {error,Reason} or ignore, the name could still be registered (either locally or in global. This is the same modification as was done for gen_server in OTP-7669.
2011-11-13Merge branch 'rickard/alloc-opt/OTP-7775'Rickard Green
* rickard/alloc-opt/OTP-7775: Optimize memory allocation Conflicts: erts/aclocal.m4 erts/emulator/hipe/hipe_bif_list.m4 erts/preloaded/ebin/erl_prim_loader.beam erts/preloaded/ebin/erlang.beam erts/preloaded/ebin/init.beam erts/preloaded/ebin/otp_ring0.beam erts/preloaded/ebin/prim_file.beam erts/preloaded/ebin/prim_inet.beam erts/preloaded/ebin/prim_zip.beam erts/preloaded/ebin/zlib.beam
2011-11-13Optimize memory allocationRickard Green
A number of memory allocation optimizations have been implemented. Most optimizations reduce contention caused by synchronization between threads during allocation and deallocation of memory. Most notably: * Synchronization of memory management in scheduler specific allocator instances has been rewritten to use lock-free synchronization. * Synchronization of memory management in scheduler specific pre-allocators has been rewritten to use lock-free synchronization. * The 'mseg_alloc' memory segment allocator now use scheduler specific instances instead of one instance. Apart from reducing contention this also ensures that memory allocators always create memory segments on the local NUMA node on a NUMA system.
2011-11-10Merge branch 'siri/stdlib/badarg-extract-child/OTP-9669'Siri Hansen
* siri/stdlib/badarg-extract-child/OTP-9669: Handle undefined pid when reporting error from supervisor
2011-11-10Merge branch 'ss/re-split-doc-bug'Henrik Nord
* ss/re-split-doc-bug: Fix re:split spec not to accept option 'global' OTP-9691
2011-11-08Merge branch 'bjorn/create-less-garbage'Björn Gustavsson
* bjorn/create-less-garbage: Optimize filename:basename/1 to produce less garbage Optimize filename:extension/1 to produce less garbage sys.c for Unix: Undo caching of utsname in os_flavor() Pre-build the tuples returned by os:type/0 and os:version/0
2011-11-07Optimize filename:basename/1 to produce less garbageBjörn Gustavsson
In most cases, we can simply return a tail of the flattened filename.
2011-11-07EEP-23: Allow variables in fun M:F/ABjörn Gustavsson
Currently, the external fun syntax "fun M:F/A" only supports literals. That is, "fun lists:reverse/1" is allowed but not "fun M:F/A". In many real-life situations, some or all of M, F, A are not known until run-time, and one is forced to either use the undocumented erlang:make_fun/3 BIF or to use a "tuple fun" (which is deprecated). EEP-23 suggests that the parser (erl_parse) should immediately transform "fun M:F/A" to "erlang:make_fun(M, F, A)". We have not followed that approach in this implementation, because we want the abstract code to mirror the source code as closely as possible, and we also consider erlang:make_fun/3 to be an implementation detail that we might want to remove in the future. Instead, we will change the abstract format for "fun M:F/A" (in a way that is not backwards compatible), and while we are at it, we will move the translation from "fun M:F/A" to "erlang:make_fun(M, F, A)" from sys_pre_expand down to the v3_core pass. We will also update the debugger and xref to use the new format. We did consider making the abstract format backward compatible if no variables were used in the fun, but decided against it. Keeping it backward compatible would mean that there would be different abstract formats for the no-variable and variable case, and tools would have to handle both formats, probably forever. Reference: http://www.erlang.org/eeps/eep-0023.html
2011-11-02Fix re:split spec not to accept option 'global'Shunichi Shinohara
2011-10-28Handle undefined pid when reporting error from supervisorSiri Hansen
2011-10-27stdlib: Remove the deprecated regexp moduleBjörn Gustavsson