José Valim
fe8fc1be25
Inline some process and node calls, closes #1808
2014-01-22 15:06:35 +01:00
Eric Meadows-Jönsson
bcb7cff5f2
Add Version.compare/2
2014-01-22 14:36:41 +01:00
José Valim
8023c29c3f
Consistently inline functions in the Kernel module by the compiler
2014-01-22 14:11:48 +01:00
José Valim
25c54dad84
Remove duplicated type assertions
2014-01-21 21:08:43 +01:00
José Valim
48b8efe9c6
Ensure proper tokenization of the ... identifier
2014-01-21 20:50:43 +01:00
José Valim
04c8ca9718
Deprecate keywords, getter and list getter functionalities of defrecordp
...
Those functionalities can still be simulated via pattern matching
and perform basic operations. The reason for this deprecation is
that we are starting to unify defrecord/defrecordp syntaxes, so
instead of doing a big change at once, we are first bringing them
to a common set of functionalities to easy migration in the future.
2014-01-21 10:15:35 +01:00
José Valim
08d69e3975
Add a test for records with default function fields
2014-01-21 09:56:16 +01:00
José Valim
b1915b1ad6
Convert HashSet to use the new trie implementation
2014-01-20 13:58:43 +01:00
José Valim
b3e07652cc
Range is no longer a record
...
The goal is to simplify and allow us to extend ranges in the future.
Also, incentivate people to use `first .. last` in pattern matching
instead of `Range[first: first, last: last]`.
2014-01-20 12:24:22 +01:00
José Valim
cad7551caf
Inspect :... and :foo@bar as valid atoms
2014-01-20 12:24:22 +01:00
José Valim
6bcb7adeb4
Clean up DictTest implementation
...
Before this commit, DictTest used too many helper functions
and used assertions in the opposite order.
2014-01-19 15:25:35 +01:00
José Valim
d311e10bea
Change HashDict implementation to use tries with compound nodes
...
The new implementation is basically a tree of tuples (tries) but
they allow compond nodes (a node with a key-value pair and a
sub-tree). This removes the need for node-expansion and also simplifies
the design structure to not require multiple stages nor buckets.
The end result is a faster HashDict implementation (about 10% faster
on access, 30% on updates), which is still small for small dicts
but about 30% bigger for large dicts (in terms of memory) and with
a much simpler implementation.
2014-01-19 13:58:45 +01:00
Eric Meadows-Jönsson
6c2744d373
Add index reflection to private records
...
Example:
defrecordp :user, [:name, age]
user(:age) #=> 2
2014-01-17 01:24:43 +01:00
José Valim
f671e1204c
Change precedence of <- to be the same as other generators
2014-01-16 20:08:55 +01:00
José Valim
4ade0f98aa
Remove deprecated code
2014-01-16 10:26:48 +01:00
José Valim
67a672e6ed
Guarantee nullary funs/macros are allowed in guards, closes #1997
2014-01-16 10:00:39 +01:00
José Valim
54e8ea13f4
Ensure heredocs are allowed in calls, closes #1998
2014-01-16 09:49:13 +01:00
José Valim
5a2e838def
Deprecate <-/2 in favor of send/2
2014-01-14 18:27:41 +01:00
José Valim
42fc70a0eb
Deprecate Enum.first/1 in favor of Enum.at/2 and List.first/1
...
The main reason for this change is because `Enum.first/1` does
not communicate that enumeration will happen, in contrast to
functions like Enum.at/2 and Enum.fetch/2 which are meant to
be used with non-indexed collections and the need for enumeration
is made a bit more obvious.
Closes #1983
2014-01-14 16:26:32 +01:00
José Valim
87fee37711
Change String.next_grapheme/1 and String.next_codepoint/1 to return nil on string end
...
This is more composable in the sense can use in in if/cond constructs
and also makes it easy to build streams. Closes #1721 .
2014-01-14 16:15:54 +01:00
José Valim
4870351d2f
Deprecate continuable heredocs, closes #1986
2014-01-14 16:03:14 +01:00
Chas Lemley
94812b4242
fix error with float midpoint rounding
...
- remove midpoint rounding option from Float.round/2
- always midpoint round away from 0
2014-01-12 12:17:50 -05:00
José Valim
11423af777
Add missing fixture file for previous commit
2014-01-11 19:11:08 +01:00
José Valim
23c67ac47c
Add a test to ensure no hanging in ParallelCompiler
2014-01-11 19:10:43 +01:00
José Valim
b4b9ecccb4
Remove :[] as a valid atom and do not allow remote container calls
2014-01-11 17:02:45 +01:00
José Valim
53b68887b6
Invert the precedence of | and when
...
Although this adds some drawbacks when it comes to typespecs,
it prepares us for when we have named patterns.
2014-01-11 16:52:46 +01:00
Eric Meadows-Jönsson
ab538670d3
Add :records, :binaries and :char_lists options to inspect/2
...
Deprecate :raw in favor of :records
2014-01-11 00:25:23 +01:00
José Valim
ba88ee7c92
Improve binary handling to properly consider chars and bitstring with specifiers
...
Closes #1963
2014-01-10 22:25:08 +01:00
José Valim
bc852a6fba
Add Enum.flat_map_reduce/3
2014-01-09 15:38:27 +01:00
José Valim
b0e1c09579
Add Stream.transform/3
...
Note: the function name may be modified before the next release.
2014-01-09 13:54:45 +01:00
José Valim
19301b9005
Small improvements to records and others
2014-01-08 14:55:28 +01:00
Eric Meadows-Jonsson
e169c0f49b
Create a signature for callbacks
2014-01-07 23:00:07 +01:00
Eric Meadows-Jonsson
8c97056b0e
Use :application.get_application/1 in stracktraces
2014-01-07 22:48:46 +01:00
Eric Meadows-Jonsson
4be1501f57
Annotated types should not be in guard vars
2014-01-07 22:10:47 +01:00
José Valim
0aff2a3139
Compile with relative paths and include apps in stacktraces
...
Closes #1964 , closes #1861
2014-01-07 11:30:44 +01:00
José Valim
7c240199f3
Improve stacktraces and error messages during expansion
2014-01-06 19:34:38 +01:00
José Valim
27467bdb67
Fix spelling of overridden
2014-01-05 12:28:11 +01:00
José Valim
952052869f
Ensure bitstring modifiers args are expanded
2014-01-04 22:44:55 +01:00
José Valim
df8b216357
Reenable case clause rewriting, closes #1972
2014-01-04 10:45:18 +01:00
José Valim
79faa1f706
Do not export case and receive vars
2014-01-04 10:45:13 +01:00
José Valim
cba7c5bd80
Only expand __ENV__.call if it is a known function
2014-01-03 22:39:48 +01:00
José Valim
5e2ea082d1
Deprecate __FILE__ in favor of __DIR__ or __ENV__.file
2014-01-02 18:10:59 +01:00
Eric Meadows-Jonsson
0a24252fca
Properly handle tuples in typespecs
2014-01-02 14:35:54 +01:00
José Valim
3a0b4988fc
Shut down GenFSM on unknown messages
2013-12-31 18:35:22 +01:00
José Valim
b7bbe13c91
Remove non ansi handling from IO.ANSI.Docs
2013-12-31 17:59:24 +01:00
José Valim
bbe63e9a93
Merge pull request #1975 from thmzlt/ansi_docs
...
Move IEx.ANSIDocs to IO.ANSI.Docs and decouple it from IEx
2013-12-31 08:47:19 -08:00
José Valim
6f0f0d5136
Merge pull request #1970 from chrismcg/gen_server_stops_on_unknown_requests
...
Stop GenServer on unknown call/cast request
2013-12-31 08:45:19 -08:00
José Valim
e055c2ccf2
Merge pull request #1961 from justinj/float-parse-negative-0
...
Fix Float.parse to handle numbers of the form "-0.x", fixes issue #1960
2013-12-31 08:44:53 -08:00
José Valim
0aee0805a9
Merge pull request #1933 from Enders/elixirc_patterns
...
Elixirc: fail when one of the provided file pattern is missing
2013-12-31 08:33:15 -08:00
José Valim
6d17b42beb
Ensure variables in remote do not leak to args
2013-12-31 11:54:15 +01:00