Age | Commit message (Collapse) | Author |
|
|
|
The type is marked as a binary() or a string() but in practice it can
be an iodata(). The test suite was updated to confirm the gen_tcp/2
and gen_udp:send/4 functions accept iodata() (iolists) packets.
|
|
* dev:
Improve types and specifications of the inet modules
|
|
* hb/inet_types_and_specs/OTP-9260:
Improve types and specifications of the inet modules
|
|
* dev:
code: Optimize purge/1 and soft_purge/1 using check_old_code/1
Add erlang:check_old_code/1
check_process_code/2: Quickly return 'false' if there is no old code
|
|
While at it, eliminate an unnecessary use of throw/catch in the
implementation of soft_purge/1.
|
|
|
|
In the location information tables in the run-time system, source
filenames that are the same as the module name plus ".erl" extension
are not stored explicitly, thus saving memory.
To take advantage of that optimization, avoid complicating the names of
files in the current working directory; specifically, make sure that
"./" is not prepended to the name.
|
|
This commit is a preparation for introducing location information
(filename/line number) in stacktraces in exceptions. Currently
a stack trace looks like:
[{Mod1,Function1,Arity1},
.
.
.
{ModN,FunctionN,ArityN}]
Add a forth element to each tuple that can be used indication
the filename and line number of the source file:
[{Mod1,Function1,Arity1,Location1},
.
.
.
{ModN,FunctionN,ArityN,LocationN}]
In this commit, the fourth element will just be an empty list,
and we will change all code that look at or manipulate stacktraces.
|
|
An incorrect spec, rpc:yield/1, has been fixed.
|
|
|
|
Two opaque types that could cause warnings when running Dialyzer have
been modified.
|
|
|
|
|
|
|
|
|
|
|
|
* mk/net-kernel-epmd-return-list:
Fix list returned by net_kernel:epmd_module
OTP-9215
|
|
* ks/hipe-ppc64:
Enable HiPE by default when compiling for PPC64
Translate RTL to PPC code on PPC64 too
Changes in ppc files for PPC64
Additions for the PPC64 backend
Changes for the PPC64 backend
Added loader for ppc64
New files for the 64-bit backends
Cleanup tags
OTP-9198
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* ks/code-spec-fixes:
Sanitize the specs of the code module
OTP-9100
|
|
Rewrote the code a bit to silence dialyzer. Seems dialyzer can't
handle a function that either returns or loops forever depending on
function argument.
|
|
Joint effort by Kostis, pan, egil & sverker
|
|
* bjorn/fix-dialyzer-warnings:
v3_kernel_pp: Eliminate dialyzer warning
inet6_tcp_dist: Eliminate dialyzer warning for "tuple fun"
|
|
* bjorn/fix-os_find_executable/OTP-8983:
Never allow os:find_executable/1 to return the path of directories
|
|
Replace the "tuple fun" with an external fun.
|
|
|
|
Change type for second parameter from binary() to iodata(), since the
function explicitly takes steps to accept lists as well as binaries.
|
|
|
|
After the addition of unicode_binary() to the file:filename() type,
dialyzer started complaining about erroneous or incomplete specs in some
functions of the 'code' module. The culprit was hard-coded information
in erl_bif_types for functions of this module, which were not updated.
Since these functions have proper specs these days and code duplication
(pun intended) is never a good idea, their type information was removed
from erl_bif_types.
While doing this, some erroneous comments were fixed in the code module
and also made sure that the code now runs without dialyzer warnings even
when the -Wunmatched_returns option is used.
Some cleanups were applied to erl_bif_types too.
|
|
Function epmd_module of net_kernel returns a list
instead of an atom, when the epmd_module-flag is used.
|
|
* ks/erl_bif_types-cleanup/OTP-8961:
Fix type information of 'file' and 'code' modules
Conflicts:
lib/hipe/cerl/erl_bif_types.erl
|
|
Also corrected type-info for bifs
|
|
|
|
|
|
|
|
Dialyzer for a long time now has had hard-coded type information about
key functions of the 'file' and 'code' modules in 'erl_bif_types'.
Some of this information was not up-to-date according to the published
Erlang/OTP documentation, while some other part contained small errors.
Now that specs are available, this information should be moved to the
corresponding files, not be hard-coded in erl_bif_types.
This change takes out all information for the 'file' module and fixes
some small errors in type information for the 'code' module.
|
|
* ta/fix-native-looping:
error_handler: add no_native compiler directive
|
|
* ks/file_open-mode:
Add the {encoding, _} options to file:open/2's modes
|
|
|
|
* maint-r14:
Prepare release
Fix that the documentation top index generator can handle an Ericsson internal application group
Teach -init_debug to print info about on_load handlers begin run
Fix hang in on_load handlers in embedded mode
Conflicts:
erts/vsn.mk
lib/kernel/vsn.mk
|
|
In embedded mode, all on_load handlers will be called after
loading all modules but before starting any servers. Therefore,
if an on_load handler calls any function in the code module that
calls the code server (such as code:priv_dir/1), there will be a
deadlock because the code server has not yet been started.
Fix this problem by invoking the on_load handlers after
having started most servers in the kernel application.
|
|
Although the {encoding, encoding()} set of options is documented in
the manual page of the 'file' module, they do not appear in the Mode
description on that page nor in the mode() type declaration.
The patch adds this information in both the code of the module and
the documentation of the module.
To avoid duplication, the declaration of the encoding() type is added
to the 'unicode' module where it most probably belongs.
While at it, added a proper declaration for posix(), took out the
now superfluous information about the types of file:open/2 from the
erl_bif_types module, and corrected the return type of file:open/2
so that it corresponds to the published documentation.
|
|
As suggested by Mikael Pettersson:
"I agree there _may_ be a recursion between the native-traps-to-beam
mechanism and the error_handler module. However, the real problem is
that the chosen mechanism (point to target MFA's BEAM code) isn't
flexible enough to handle newer features like on_load or (apparently)
a native-mode error_handler.
My planned fix is to make remote calls link to the target's Export*
instead, just like BEAM does, which should solve the problems. This
will however require HiPE to use different kinds of trap-to-beam stubs
for remote and local calls, since local calls must not and often
cannot go via Export entries.
A simpler workaround for the error_handler issue (which I couldn't
reproduce) is to just never compile error_handler to native code. It's
not like there's a lot to gain by doing that. Please try the patch
below."
Patch has been tested and confirmed to make --enable-native-libs
useable.
Signed-off-by: Mikael Pettersson <[email protected]>
Acked-by: Tuncer Ayaz <[email protected]>
|