Commit Graph

68 Commits

Author SHA1 Message Date
Aleksey Kladov
98baa9b569 Rename ra_arena 2020-08-12 16:22:05 +02:00
Aleksey Kladov
6f8aa75329 Rename RecordLit -> RecordExpr 2020-07-30 16:21:30 +02:00
Aleksey Kladov
b4443b0398 Bump macro recursion limit in release 2020-07-11 20:01:56 +02:00
Aleksey Kladov
a8891ae3ca More tight recursion limit when expanding macros in function bodies
cc #4944
cc #5317

This doesn't fully close #4944 -- looks like we hit SO in syntax
highlighting, when we use `Semantics::expand_macro`.

Seems like we need to place expansion limit on the macro itself (store
it as a part of MacroCallId?)!
2020-07-11 18:39:49 +02:00
Aleksey Kladov
b85042601d Goto type definition works for self 2020-07-10 14:08:35 +02:00
Aleksey Kladov
fac7b0e252 Don't guess macro expansion crate 2020-06-11 12:13:14 +02:00
Benjamin Coenen
c6143742bd add support of feature flag for runnables #4464
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
2020-05-21 10:48:42 +02:00
Benjamin Coenen
831bb1cf91 refactor: use attrsOwner directly in is_cfg_enabled
Signed-off-by: Benjamin Coenen <5719034+bnjjj@users.noreply.github.com>
2020-05-05 09:34:07 +02:00
Edwin Cheng
bdcf6f5658 Introduce LowerCtx for path lowering 2020-05-01 20:01:17 +08:00
veetaha
f52e2f6840 Fix typo 2020-04-25 20:49:51 +03:00
Aleksey Kladov
302bf97bbf Don't expose impl details of SyntaxPtr 2020-04-17 12:25:41 +02:00
Aleksey Kladov
0aece75cdd Remove dead code 2020-04-11 19:36:31 +02:00
Aleksey Kladov
7a39bc3ba2 Make records grammar more orthogonal
We used

  name [: expr]

grammar before, now it is

  [name :] expr

which makes things simpler
2020-04-11 19:20:41 +02:00
Aleksey Kladov
38c67e5c0d Avoid cyclic queries in name resolution when processing enums 2020-04-11 17:52:26 +02:00
Aleksey Kladov
deb40d52aa Align naming 2020-04-11 17:20:26 +02:00
Aleksey Kladov
e9519e1035 Pull Expander up 2020-04-11 17:09:50 +02:00
Aleksey Kladov
6b0870d12e Simplify 2020-04-11 17:00:31 +02:00
Aleksey Kladov
c1244c853c Forward compat 2020-04-11 00:27:00 +02:00
Edwin Cheng
92cc6c9816 Add recursive limit in expression macro expansion 2020-03-21 23:58:47 +08:00
Aleksey Kladov
f840fcb2f5 Simplify Arena to use a generic index 2020-03-19 18:46:30 +01:00
Aleksey Kladov
9faea2364d Use dyn Trait for working with databse
It improves compile time in `--release` mode quite a bit, it doesn't
really slow things down and, conceptually, it seems closer to what we
want the physical architecture to look like (we don't want to
monomorphise EVERYTHING in a single leaf crate).
2020-03-16 17:42:30 +01:00
Edwin Cheng
fe78a14bbb Support local macro_rules 2020-03-14 14:25:51 +08:00
Aleksey Kladov
57da3df99a Explicitly remember desugard pats 2020-03-06 15:17:48 +01:00
Aleksey Kladov
5ffddc4b92 Explicitly remember desugard exprs 2020-03-06 15:11:05 +01:00
Aleksey Kladov
fb5891c433 Source map returns a result
cc #2236
2020-03-06 14:44:44 +01:00
Edwin Cheng
2d4e79e1e6 Introduce AsMacroCall trait 2020-02-17 12:57:24 +08:00
Edwin Cheng
12cc2ed557 Use pre-stored macro file 2019-12-23 21:56:10 +08:00
Edwin Cheng
16156d766d Add macro call support for type_of 2019-12-23 13:19:01 +08:00
Aleksey Kladov
baee746185 Share impl Scope between modules and blocks 2019-12-22 15:52:35 +01:00
Aleksey Kladov
d4b135f38c Optimize and profile 2019-12-21 18:46:21 +01:00
bors[bot]
6eab968c60
Merge #2624
2624: Separate module item from module scope r=matklad a=matklad

bors r+

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
2019-12-20 19:51:03 +00:00
Edwin Cheng
ad81d1dbc1 Add support macros in impl blocks 2019-12-21 03:37:03 +08:00
Aleksey Kladov
0f212b3798 Move ModuleScope to a new module 2019-12-20 16:52:02 +01:00
Aleksey Kladov
3d4b48e481 Fix resolve for field init shorthand 2019-12-20 14:48:14 +01:00
Aleksey Kladov
a04177f135 Add local functions to bodies 2019-12-20 11:52:17 +01:00
Aleksey Kladov
5bd8de3f5e Allow storing defs in bodies 2019-12-19 18:09:50 +01:00
Aleksey Kladov
04715cbe1c Forbid <T>::foo syntax in mod paths 2019-12-18 17:41:33 +01:00
Aleksey Kladov
2619950b3b Use different types for path with and without generics 2019-12-14 19:15:40 +01:00
Edwin Cheng
509fedd9d2 Remove MacroFileKind 2019-12-08 16:16:52 +08:00
Florian Diebold
18f6a995d0 Add expansion infrastructure for derive macros 2019-12-05 17:23:09 +01:00
ice1000
009437f5d9 Replace ra_hir_expand::either with crate 2019-12-03 11:07:56 -05:00
Edwin Cheng
bb601e7eaf Add BuiltinShadowMode 2019-11-30 23:29:21 +08:00
Aleksey Kladov
8f1f5a783a Move source-related traits to a separate module 2019-11-28 19:05:21 +03:00
Aleksey Kladov
ccd1b0800a Rename Source -> InFile 2019-11-28 12:50:26 +03:00
Aleksey Kladov
d9a36a736b Rename module_id -> local_id 2019-11-27 21:31:51 +03:00
Edwin Cheng
447268ceac Hide MacroCallLoc 2019-11-27 01:33:08 +08:00
Aleksey Kladov
d157812cd1 Docs 2019-11-24 20:39:48 +03:00
Aleksey Kladov
434f108ada Simplify 2019-11-24 19:01:19 +03:00
Aleksey Kladov
99af523b68 Cleanup 2019-11-24 17:36:06 +03:00
Aleksey Kladov
e0b06cb672 Switch to StaticLoc for statics 2019-11-24 15:18:12 +03:00