José Valim
e424f02812
Ensure aliases defined in macros do not leak
2013-11-30 18:02:46 +01:00
José Valim
00431ebecb
Warnings rely on stdio and should be sync
2013-11-29 22:37:48 +01:00
José Valim
4ed4f52121
Fix regression when using in with module attributes
2013-11-28 13:56:37 +01:00
José Valim
5c00882bff
Update CHANGELOG
2013-11-25 11:39:02 +01:00
José Valim
043edd4990
location: :keep only affect function definitions
...
This commit changes how metadata is stored once location: :keep
is used and also removes the __scope__ special form.
Closes #1877
2013-11-25 11:35:00 +01:00
José Valim
0a84b90373
Move super? to Elixir as well
2013-11-23 11:09:51 +01:00
José Valim
f98cda71c0
Implement var! and alias! in Elixir
2013-11-23 10:54:40 +01:00
José Valim
b28c95d31a
Move case/try/receive to special forms
2013-11-23 10:35:10 +01:00
José Valim
abec6af3ac
Move function/macro definitions to Kernel
2013-11-23 10:17:57 +01:00
José Valim
0d3aa7fd66
Improve some Kernel error messages
2013-11-06 16:14:31 +01:00
José Valim
e999642a8e
Improve syntax error on invalid calls
...
Closes #1847
2013-11-04 12:32:17 +01:00
José Valim
aba0d5ba3f
Simplify current module macro handling
2013-11-01 16:03:13 +01:00
José Valim
d334c1d6e4
Add tests for LexicalTracker
2013-11-01 16:03:13 +01:00
José Valim
d856e667b9
Add warnings for unused aliases
2013-11-01 16:03:12 +01:00
José Valim
3c151d5357
Add Kernel.LexicalTracker
2013-11-01 16:03:12 +01:00
José Valim
821b7c6f76
Ensure Enum.member? uses match (===)
2013-10-31 11:36:05 +01:00
José Valim
9897b894be
Deprecate x in y inside matches
2013-10-31 11:36:05 +01:00
José Valim
f1e2fcf9f9
Same module variables must be explicitly shared
...
Prior to this commit, the following code would work:
defmodule Hello do
defmacro write do
quote do
a = 1
end
end
defmacro read do
quote do
a
end
end
end
require Hello
Hello.write
Hello.read
Although this is convenient, it has many issues:
1. It is not clear at any point the intent of sharing the variables
in between the macros
2. Whenever macros from the same module are nested, there is a chance
a variable used before and after the nesting to be overriden
We address this issue by only allowing variables explicitly marked
with var! to be shared. Here is how the example above should be updated:
defmodule Hello do
defmacro write do
quote do
var!(a, Hello) = 1
end
end
defmacro read do
quote do
var!(a, Hello)
end
end
end
require Hello
Hello.write
Hello.read
2013-10-30 16:15:19 +01:00
José Valim
992ac67512
Improve coverage for location: :keep
2013-10-30 16:15:19 +01:00
José Valim
67ac77fdb3
Sigils can now handle balanced tokens as in %s(f(o)o)
...
Closes #1480
2013-10-26 14:08:04 +02:00
James Fish
446f5dc2c3
Document try else clause
2013-10-24 21:11:58 +01:00
José Valim
cd74bd5d54
Also deprecate atom<->binary conversions with encoding
2013-10-18 22:18:57 +02:00
José Valim
997a0857c3
Avoid flattening in access[...], closes #1763
2013-10-18 14:54:49 +02:00
José Valim
3cf9774b92
Improve warn on invalid expressions
2013-10-07 20:16:54 +02:00
José Valim
60b2928678
Ensure &() works on blocks with one expressoin, closes #1704
2013-09-29 21:53:04 +02:00
José Valim
4b317a75d8
Save typespecs attributes with proper line numbers, closes #1613
2013-09-29 13:15:33 +02:00
José Valim
212acf437a
Provide better exceptions for invalid unquote args, closes #1680
2013-09-11 12:19:41 -03:00
José Valim
14272c98b4
Improve invalid match and guard errors, closes #1673
2013-09-11 11:21:10 -03:00
José Valim
f3f64cdba2
Move to capture syntax
2013-09-10 23:33:53 -03:00
José Valim
c3bdfc9ba7
No need to mark typedoc as persisted if we are manually persisting it
2013-09-10 12:46:22 -03:00
José Valim
262e8b5f22
Avoid duplicatation by making the typedoc signature always an empty list
2013-09-10 12:31:20 -03:00
José Valim
2f5afcaab9
Merge pull request #1637 from pminten/typedoc-rebased
...
Typedoc rebased
2013-09-10 08:01:18 -07:00
José Valim
b39a5d8632
Deprecate %b and %B in favor of %s and %S
2013-09-03 13:14:13 -03:00
José Valim
4caa2e01f1
Move is_odd and is_even to Integer
2013-09-03 09:41:55 -03:00
José Valim
10a795ff44
Only support iolists on IO
2013-09-02 16:01:10 -03:00
José Valim
488344839a
Allow any function identifier as a variable, closes #1649
2013-08-25 10:28:55 -03:00
José Valim
4a0db2e974
Handle more types on bitsyntax.
2013-08-24 16:07:55 -03:00
José Valim
55aad68512
Splice nested binaries with default types and size
2013-08-24 15:55:24 -03:00
José Valim
3b4954b652
Merge pull request #1643 from pminten/elixirc-silent
...
Add --verbose to elixirc
2013-08-24 11:15:21 -07:00
Peter Minten
4c28f325e3
Supress 'Compiled' msg by default in elixirc
...
Adds a --verbose option to elixirc
This fixes #1618
2013-08-24 13:30:34 +02:00
José Valim
a6cdc835a1
No need to wrap quote do: nil in a block
2013-08-23 11:22:11 +02:00
Peter Minten
a5ea8a63bf
Use typedoc attribute to store typedocs.
...
This requires a bit of a workaround because `typedoc` is also used to store the
doc of the next type to be defined. We store typedocs in the docs table when
types are defined and later filter them out and put them into `typedoc`.
2013-08-22 16:30:24 +02:00
Peter Minten
742258340c
Remove unneeded empty lines in the typedoc tests.
2013-08-22 16:30:24 +02:00
Peter Minten
1be3335f0b
Add a @typedoc attribute to document types
...
Also a new `Kernel.Typespec.beam_typedocs` function to get the typedoc
information.
2013-08-22 16:30:24 +02:00
José Valim
0510512375
Deprecate to_binary in favor of to_string
...
We also rename Binary.Chars to String.Chars.
As Binary.Chars was the protocol used for interpolation,
it is semantically correct to have a protocol that works
on strings, instead of raw binaries.
2013-08-22 12:19:30 +02:00
José Valim
0e1aac32f5
import accept :functions and :macros as values in :only
...
This commit removes the previous ambiguous syntax:
import :functions, Foo
In favor of:
import Foo, only: :functions
2013-08-22 10:34:45 +02:00
José Valim
8b02a2a7a0
Convert external functions into quoted expressions
2013-08-20 23:52:00 +02:00
José Valim
3e1099830a
Properly handle @file that comes from warnings
2013-08-20 11:39:29 +02:00
José Valim
f84b4121ce
Allow << _ :: utf8 >> <> binary in matches, closes #1619
2013-08-18 14:36:54 +02:00
José Valim
ff2af55e1d
Improve warning for ungrouped clauses
2013-08-18 10:05:36 +02:00