Yurii Rashkovskii
ed89fdb732
Support for decreasing ranges
...
Closes #518
2012-10-09 13:29:12 -07:00
José Valim
98efb89125
Make +:foo behaviour consistent with foo:bar (both still raise a warning though)
2012-10-09 21:56:36 +02:00
José Valim
11f934b74a
Protocols are powered by behaviours behind the scenes
2012-10-08 20:13:45 +02:00
José Valim
69e36c731c
Simplify __scope__ API
2012-10-05 18:26:52 -07:00
José Valim
626ed9532b
Erlang. syntax is deprecated in favor of simply using atoms
2012-10-05 17:08:22 -07:00
José Valim
441bf29f16
Remove special case for specs in elixir_module.erl
...
Previously, since the functions were not concrete
but stubs replaced at compilation time, we had to
special the module definition to not actually include
the specs, which would become compilation errors.
Now we provide a concrete implementation of the
functions and therefore the spec will be available
in the final source. Those implementations are not
actually invoked in practice, since they are still
transformed into erlang ones for performance reasons.
2012-10-05 15:45:29 -07:00
José Valim
fac57e78b2
Ensure Kernel.__info__(:functions|:macros) returns the complete set
2012-10-05 15:45:28 -07:00
José Valim
e6dba433eb
Add Module.create
2012-10-03 23:27:34 -07:00
José Valim
0632e01f44
Use references instead of relying on file names
2012-10-01 23:39:40 -07:00
José Valim
001c242e74
Reset internal variable data when assigning binding
2012-10-01 14:24:01 -07:00
José Valim
a22530baf9
Simplify import api
2012-09-28 15:48:23 -07:00
José Valim
4859264fe3
Import ignores function/macros starting with underscore, default callbacks to underscore style
2012-09-27 16:00:26 -07:00
José Valim
010faad0ce
Improve tests for bitstring macros
2012-09-26 23:30:45 -05:00
José Valim
e42840bf81
Allow macros as bitstrings specifiers
2012-09-26 20:43:25 -05:00
José Valim
19065ac43e
Simplify protocol handling
2012-09-25 14:06:22 -05:00
José Valim
fe788964bd
Add optional comma in lists, tuples, bit strings and keywords, closes #479
2012-09-23 11:43:38 -05:00
José Valim
b2037b0fcc
Module.read_attribute and Module.add_attribute deprecated
...
In favor of `Module.get_attribute` and `Module.put_attribute`
which mimics Dict API
2012-09-18 13:51:32 +02:00
Yurii Rashkovskii
9e835246d6
defmodule returns module name, binary and the result
...
Previously, 58eea96fc2 was
attempting to solve the ambiguity of records and defmodule result.
This solves the problem completely by tagging defmodule results with
the :module atom and it brings the module name back into the tuple
2012-09-13 12:35:21 -07:00
José Valim
d025e9f149
Fix regression in parser
2012-09-13 14:01:21 +02:00
José Valim
58eea96fc2
defmodule only returns the result and the binary
...
We avoid returning { module, binary, result } because
it can be mistakenly confused as a record named module.
Before this patch, defrecord Foo, bar: nil, baz: nil
in IEx was returning:
Foo[bar: <<binary>>, baz: nil]
2012-09-13 13:56:43 +02:00
José Valim
69c198630c
Inspect accepts limit and raw as options
2012-09-13 13:23:10 +02:00
José Valim
9fceea3284
GenServer behaviour also defines init, closes #467
2012-09-13 11:30:55 +02:00
José Valim
e4ad1c14e4
Docs for functions without implementation are automatically marked as defcallback
2012-09-12 12:59:22 +02:00
José Valim
c7a7022bf3
Properly expand other unquote expressions
2012-09-11 22:19:31 +02:00
josh rotenberg
03c12b2ede
s/keywords list/keyword list/ in docs
2012-09-11 07:45:08 -07:00
José Valim
f5560da26d
Docs now use the new on_definition hook
2012-09-10 22:00:25 +02:00
José Valim
6c96c3473a
Add support to on_definition hooks, closes #448
2012-09-10 21:50:23 +02:00
José Valim
6ffcd51f1a
Make overridable internal function more readable
2012-09-10 20:47:41 +02:00
José Valim
26204441bb
Implement new bitstring syntax, closes #421
2012-09-10 13:45:45 +02:00
José Valim
5ba2f24400
Merge pull request #429 from thomasc/features/mix-escriptize
...
Add initial escript support to mix
2012-09-09 23:44:23 -07:00
José Valim
aebbf68d73
Binary module is gone, long live String
2012-09-09 23:14:55 +02:00
José Valim
ce37416cc6
defmodule returns the module binary
2012-09-07 19:19:05 +02:00
José Valim
d14687b3bc
Raw function definition now evaluates all arguments
...
This applies to def/4, defp/4, defmacro/4, defmacrop/4.
The previous behaviour was accidental and did not properly
evaluate all arguments.
2012-09-07 12:19:03 +02:00
José Valim
0dcf8c23d4
Ensure pipe op can start at new line, closes #450
2012-09-04 11:49:04 +02:00
José Valim
6a516efc1b
Allow mod.unquote(fun)(args) on quote
2012-08-28 16:10:08 -03:00
José Valim
c229d34c03
Fix precedene of @ operator
2012-08-27 19:12:09 -03:00
José Valim
cb78831b4e
Properly expand access on module attributes
2012-08-27 15:54:43 -03:00
José Valim
7d92b1b8e6
Give apps back in the proper order
2012-08-27 15:40:01 -03:00
José Valim
e0d585b1d2
Improvements to the access protocol
...
* Allow @config[:access] to expand to (@config)[:access]
* Allow nil[:access] to work as expected
2012-08-24 13:03:02 -03:00
José Valim
2a94699d79
Allow files to be unloaded
2012-08-21 10:37:31 -03:00
José Valim
cd6aedc8f2
Code.require_file blocks until file is available
2012-08-20 18:14:41 -03:00
José Valim
74a8cc8c90
compile callbacks must be executed on reverse order
2012-08-17 19:16:07 -03:00
José Valim
4df5019b7e
Fix build for bootstraping
2012-08-17 16:22:34 -03:00
José Valim
24bc3668a6
Add Enum.count, allow behaviour to define default functions
2012-08-17 16:08:38 -03:00
José Valim
9aa32423b0
Provide some behaviour conveniences
2012-08-17 15:49:00 -03:00
José Valim
bc4918ee0d
Ensure quoted variables are properly carried in clauses
2012-08-17 11:11:04 -03:00
José Valim
bd09818898
Ensure hygiene works with temp vars
2012-08-17 10:48:48 -03:00
José Valim
6abdea44db
Use orddicts to store vars, since we rarely have more than 20 vars
2012-08-17 09:32:18 -03:00
José Valim
4dc1431179
Matching ^ inside quotes should work as expected
2012-08-17 08:50:17 -03:00
José Valim
705aa84c5a
Fix fake warning when a match happens after a default arg
2012-08-16 14:19:07 -03:00