Age | Commit message (Collapse) | Author |
|
To ensure that 'master' compiles when we merge 'maint' to it,
regardless of which encoding is default in 'master', all source
files with non-ascii characters *must* have the encoding specified.
|
|
Tuples funs were removed in de7e01c958ff7c9e6da4034a53567a30a4ae5792,
but it was still possible to evaluate tuple funs in the shell.
|
|
Unicode related.
|
|
|
|
Tuple funs were deprecated in R15B (in commit a4029940e309518f5500).
|
|
|
|
Parameterized modules are not supported by HiPE.
|
|
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
|
|
Running Dialyzer on the test suites revealed a few type errors.
|
|
|
|
In the following code:
m(<<Sz:8,_:Sz/binary>>) ->
Sz = wrong.
the Sz variable is supposed to be bound in the function header and the
matching "Sz = wrong" should cause a badarg exception. But what
happens is that the Sz variables seems to be unbound and the matching
succeds and the m/1 function returns 'wrong'.
If the Sz variable is used directly (not matched), it will have
the expected value. Thus the following code:
m(<<Sz:8,_:Sz/binary>>) ->
Sz.
will correctly return the value of Sz that was matched out from
the binary.
Reported-by: Bernard Duggan
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<<A:0>> will always produce an empty binary, regardless of the
type of A. The bug is in the run-time system. Fix it so that a
non-numeric value for A will cause a badarg exception.
Reported-by: Zvi
|
|
|