aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_hir_expand
Commit message (Collapse)AuthorAgeFilesLines
* Add extern sourceEdwin Cheng2020-03-111-1/+2
|
* Add and fix testsEdwin Cheng2020-03-101-60/+121
|
* Add resolve_extern_path in DBEdwin Cheng2020-03-101-1/+8
|
* Merge #3513bors[bot]2020-03-091-4/+67
|\ | | | | | | | | | | | | | | | | | | | | 3513: Completion in macros r=matklad a=flodiebold I experimented a bit with completion in macros. It's kind of working, but there are a lot of rough edges. - I'm trying to expand the macro call with the inserted fake token. This requires some hacky additions on the HIR level to be able to do "hypothetical" expansions. There should probably be a nicer API for this, if we want to do it this way. I'm not sure whether it's worth it, because we still can't do a lot if the original macro call didn't expand in nearly the same way. E.g. if we have something like `println!("", x<|>)` the expansions will look the same and everything is fine; but in that case we could maybe have achieved the same result in a simpler way. If we have something like `m!(<|>)` where `m!()` doesn't even expand or expands to something very different, we don't really know what to do anyway. - Relatedly, there are a lot of cases where this doesn't work because either the original call or the hypothetical call doesn't expand. E.g. if we have `m!(x.<|>)` the original token tree doesn't parse as an expression; if we have `m!(match x { <|> })` the hypothetical token tree doesn't parse. It would be nice if we could have better error recovery in these cases. Co-authored-by: Florian Diebold <[email protected]>
| * Move hypothetical expansion to hir_expandFlorian Diebold2020-03-082-17/+35
| |
| * Remove TODOsFlorian Diebold2020-03-071-5/+6
| |
| * Try to complete within macrosFlorian Diebold2020-03-072-9/+53
| |
* | Add parse_to_token_treeEdwin Cheng2020-03-081-4/+4
|/
* Prevent include! macro include itselfEdwin Cheng2020-03-071-1/+6
|
* Fix test and add more commentEdwin Cheng2020-03-071-1/+4
|
* Use a not so dummy implementation of env macroEdwin Cheng2020-03-071-1/+1
|
* Implment include macroEdwin Cheng2020-03-063-19/+62
|
* Add comment for parents loggingEdwin Cheng2020-03-041-7/+12
|
* Fix whitespace in testsEdwin Cheng2020-03-042-3/+3
|
* Fix #3436Edwin Cheng2020-03-041-6/+2
|
* Add more logEdwin Cheng2020-03-041-0/+9
|
* Fixed a typo in commentEdwin Cheng2020-03-031-1/+1
|
* Fix panic on eager expansionEdwin Cheng2020-03-031-2/+18
|
* Fix for rebasingEdwin Cheng2020-03-031-3/+14
|
* Move pub function firstEdwin Cheng2020-03-031-24/+24
|
* Add doc about eager expansion name resolutionEdwin Cheng2020-03-031-0/+19
|
* Implement concat macroEdwin Cheng2020-03-037-70/+279
|
* Add LazyMacroIdEdwin Cheng2020-03-035-16/+56
|
* Fix a bug for single dollar sign macroEdwin Cheng2020-03-031-5/+10
|
* Update versionsKirill Bulatov2020-02-181-2/+2
|
* More manual clippy fixesKirill Bulatov2020-02-182-10/+6
|
* Run cargo +nightly fix --clippy -Z unstable-optionsKirill Bulatov2020-02-183-5/+4
|
* Add couple of utility methodsAleksey Kladov2020-02-121-3/+19
|
* Remove ImportResolver-related stubsKirill Bulatov2020-02-091-7/+0
|
* Code review fixesKirill Bulatov2020-02-021-6/+7
|
* Require ModPath for importingKirill Bulatov2020-02-021-0/+6
|
* Prefer imports starting with stdKirill Bulatov2020-01-271-0/+2
|
* Use dummy value for line! and column! macroEdwin Cheng2020-01-141-83/+13
|
* Use attr location for builtin macro goto-impEdwin Cheng2020-01-121-0/+15
|
* Apply review suggestionsFlorian Diebold2020-01-111-4/+0
|
* Some more refactoringFlorian Diebold2020-01-111-0/+10
|
* basics workingFlorian Diebold2020-01-111-0/+4
|
* Merge #2795bors[bot]2020-01-111-2/+10
|\ | | | | | | | | | | | | | | | | | | | | | | 2795: Use dummy value for macro file in bulitin macros r=matklad a=edwin0cheng This PR skip the actual line and column computation for `MacroFile` and return a dummy value instead. Related to #2794 Co-authored-by: Edwin Cheng <[email protected]>
| * Use dummy value for macro file in bulitin macrosEdwin Cheng2020-01-111-2/+10
| |
* | Add test for macro expansion in various expressionsFlorian Diebold2020-01-101-1/+0
|/
* Add missing expr cases for expand macroEdwin Cheng2020-01-101-1/+23
|
* Expand PAREN_EXPR as expressionEdwin Cheng2020-01-101-0/+1
|
* Fix panic in tuple fieldsAleksey Kladov2020-01-071-1/+4
|
* Add dummy implementations of env! and option_env! builtinsFlorian Diebold2019-12-213-43/+99
| | | | | | They don't do anything except return the correct type. Also refactor the builtin macro tests a bit.
* Merge #2625bors[bot]2019-12-212-6/+5
|\ | | | | | | | | | | | | | | 2625: Clippy lints r=matklad a=kjeremy Co-authored-by: kjeremy <[email protected]>
| * Clippy lintskjeremy2019-12-202-6/+5
| |
* | Add support macros in impl blocksEdwin Cheng2019-12-201-0/+1
|/
* Merge #2614bors[bot]2019-12-201-1/+1
|\ | | | | | | | | | | | | | | 2614: Clippy cleanup r=matklad a=kjeremy Just a few tweaks from the latest clippy. There are a lot more but we should probably tweak our settings. Co-authored-by: kjeremy <[email protected]>
| * Remove useless clonekjeremy2019-12-201-1/+1
| |
* | Add std::ops::Index support for inferingEdwin Cheng2019-12-191-0/+1
|/