José Valim
488344839a
Allow any function identifier as a variable, closes #1649
2013-08-25 10:28:55 -03: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
vanstee
ad67e4935a
Return error when tokenizing oversized atom
...
When "atomizing" an unsafe string, we need to make sure the atom length
is going to be less than the system limit (255). Any function calling
`unsafe_to_atom` checks for an error and returns it if present.
2013-08-10 17:10:47 -04:00
José Valim
b5428adda6
Add &local/arity and &Remote.fun/arity
2013-07-31 12:58:07 +02:00
José Valim
a013b39b8f
Do not double escape strings inside interpolation, closes #1494
2013-07-25 14:34:13 +02:00
José Valim
7ad7847596
Rearrange how ambiguous ops are handled, closes #1378
2013-07-06 12:32:22 +02:00
José Valim
6d491325d5
Update and remove out of date erl tests
2013-07-04 11:40:00 +02:00
José Valim
903aa60fec
Finish operator table clean up
2013-06-23 13:18:25 +02:00
José Valim
969bc968ee
Move ++, --, ** and // to new table
2013-06-23 13:18:25 +02:00
José Valim
68c890e179
Move and and or operators to the new table
2013-06-23 13:18:25 +02:00
José Valim
dd573c9806
Initial work cleaning up op table
2013-06-23 13:18:25 +02:00
José Valim
151695b43c
Add tests for nested whens
2013-06-22 18:53:18 +02:00
José Valim
5247961185
Optimize temp_vars lookup
2013-06-21 11:43:41 +02:00
José Valim
c4dcaf540d
Slight clean up on erlang tests
2013-06-20 22:44:22 +02:00
José Valim
21db352039
Always print warnings to stderr
2013-06-15 09:32:53 +02:00
José Valim
2c98c0999d
An Elixir module now translates to Elixir.Module instead of Elixir-Module
2013-05-23 14:36:56 +02:00
José Valim
9b0353a747
Improve error messages when there is a space in between function name and parenthesis
2013-05-21 12:57:22 +02:00
José Valim
e18c1602ba
Only add quoted: true to required ast nodes
2013-05-13 15:56:15 -06:00
José Valim
f38cf28cbd
Store in the AST if contents come from a quoted expression
...
This provides a more robust way of checking from where
the original expressions are coming from compared to the
lexical check_clauses field we had in elixir_scope.
A direct consequence of this commit is that, the following
code:
defrecord Sample, [:hello] do
import List
end
Now raises a warning if the List import is not used,
where it didn't previously.
2013-05-13 15:56:15 -06:00
José Valim
b90b8d1385
Improve cons cell and other operators precedence, closes #862
2013-05-12 14:24:35 -06:00
José Valim
f484c9960f
Add a test for inline keyword blocks
2013-04-30 23:34:24 -07:00
José Valim
70432ca7f2
Remove deprecations
2013-04-20 19:22:13 -06:00
José Valim
5d1d3f23e9
Merge pull request #922 from bellthoven/fix_function_calls
...
Allow 'foo . (42)' calls
2013-04-12 18:44:29 -07:00
José Valim
4096b31cfe
Ensure the proper scope is passed on args call, closes #949
2013-04-12 18:08:56 -07:00
Gustavo Dutra
9016a18fa5
Allow multiple lines 'foo . ()' calls
2013-04-07 15:00:54 -03:00
Gustavo Dutra
bd6f27a5d5
Allow 'foo . (42)' calls
2013-04-07 01:38:30 -03:00
José Valim
6024014482
Improve error message on unclosed interpolation/string, closes #794
2013-03-17 13:57:20 -06:00
José Valim
8994feb0a3
Fix unused vars warnings
2013-02-02 13:33:00 -07:00
José Valim
fef7ef7233
Ensure consistent use of stab operator in do/end, parens and fn/end, closes #780
2013-01-27 11:00:59 -07:00
José Valim
abb1ae981a
Add hygienic imports to macros
2013-01-21 20:45:49 -07:00
José Valim
89cbe93bba
The AST now allows metadata to be attached to each node
...
This means the second item in the AST is no longer an integer
(representing the line), but a keywords list. Code that relies
on the line information from AST or that manually generate AST
nodes need to be properly updated.
2013-01-21 15:42:03 -07:00
José Valim
b9313340b7
Keep \377 and 0377 as the octal syntax, closes #737
2012-12-31 13:46:56 +01:00
mururu
5711d74fd9
Support "\a"
2012-12-27 09:18:13 +09:00
mururu
a00aaf48e3
Fix indent
2012-12-26 15:42:47 +09:00
Kim Shrier
54d74efa04
Update octal and hex escapes for characters, char lists, and strings to all accept
...
the same syntax and be case insensitive. Also relocated the character type macros
into lib/elixir/include/elixir.hrl so that they didn't need to be defined in both
lib/elixir/src/elixir_interpolation.erl and lib/elixir/src/elixir_tokenizer.erl.
Added to the erlang and elixir unit tests to test the new syntax.
2012-12-23 20:05:23 -07:00
Kim Shrier
d23cc079ad
add octal and hex escapes for characters
2012-12-22 03:16:12 -07:00
José Valim
ea1a79a156
Merge pull request #730 from kimshrier/case_insensitive_hex_interpolation
...
add code and tests for case insensitive hex interpolation.
2012-12-22 00:39:22 -08:00
Kim Shrier
d5613ed380
add code and tests for case insensitive hex interpolation.
2012-12-21 23:32:01 -07:00
mururu
3e2172e646
modify atom with interpolation tokenizer
2012-12-22 14:46:43 +09:00
José Valim
305ad0b9c0
Support else clauses on try
2012-12-16 22:03:49 +01:00
José Valim
290b0ef894
:... is a valid atom, closes #697
2012-12-06 09:23:24 +01:00
José Valim
9b3d851a9c
Deprecate record default-based generated functions
2012-12-01 11:14:45 +01:00
José Valim
a061528731
Ensure IEx runs only after Elixir's CLI process its options
2012-11-30 17:07:12 +01:00
José Valim
ed0eff4d1d
Fix failing erlang tests
2012-11-25 18:25:03 +01:00
José Valim
7ddab53707
Also allow multiclause functions on fn
...
The function macro is still necessary for function
retrieval and it will be extended when R16 is out
to supported named functions
2012-11-25 00:06:39 +01:00
José Valim
32764b3370
Copy all __ENV__ information on eval
2012-11-15 10:01:18 +01:00
José Valim
02e63e4849
Ensure parenthesis can be used in macros and fn shortcut, closes #634
2012-11-08 15:52:52 +01:00
José Valim
78c6c7201f
Keywords are allowed after . identifier, closes #621
2012-11-02 10:05:17 +01:00
José + Yehuda
e03bf4d7d8
Initial work on Calendar.format (based on ICU)
2012-10-21 19:43:11 +02:00
José Valim
ca0dbe8f46
Merge pull request #555 from elixir-lang/jv-unordered-keywords
...
Unordered keywords
2012-10-19 02:54:14 -07:00