Commit Graph
22 Commits
Author SHA1 Message Date
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 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 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 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 ce37416cc6 defmodule returns the module binary 2012-09-07 19:19:05 +02:00
José Valim 74a8cc8c90 compile callbacks must be executed on reverse order 2012-08-17 19:16:07 -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 9b0f00f075 Improvements to the record API 2012-08-15 11:56:38 -03:00
José Valim c2746101ab Expand @attributes in Macro.expand if possible 2012-08-04 13:02:19 -03:00
José Valim fb255e4f82 Ensure IEx.Helpers is loaded before getting funs 2012-07-26 22:28:42 +02:00
José Valim 15defaab04 Show a warning instead of exception on module redefinition, closes #396 2012-07-23 18:21:12 +02:00
José Valim 576492ae48 Add Code.ensure_compiled 2012-07-23 09:51:15 +02:00
José Valim 7d1ef13f17 Rename Elixir.Builtin to Kernel, according to #390 2012-07-22 11:23:35 +02:00
José Valim 1077e64126 Deprecate Module.function_defined? in favor of Module.defines? 2012-07-21 23:32:16 +02:00
José Valim d984f4b545 Typespecs now support macros, closes #385 2012-07-20 10:29:55 +02:00
José Valim 1b4603160c Add elixir's parse transform to be used with erlang code 2012-07-12 11:29:46 +02:00
José Valim 439971e5b1 Small fixes to typespecs 2012-07-10 19:39:43 +02:00
José Valim d5031b6347 Move all code to erlang style apps 2012-07-05 20:20:16 +02:00