aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_parser/src/grammar/expressions.rs
Commit message (Collapse)AuthorAgeFilesLines
* Fix parsing of blocks without `{`Aleksey Kladov2020-05-021-14/+1
|
* Introduce EffectExprAleksey Kladov2020-05-021-11/+2
|
* Make records grammar more orthogonalAleksey Kladov2020-04-111-12/+25
| | | | | | | | | | | | We used name [: expr] grammar before, now it is [name :] expr which makes things simpler
* Rename some tokensAleksey Kladov2020-04-101-1/+2
|
* CleanupsAleksey Kladov2020-04-031-2/+2
|
* Fix parsing of stement-ish binary expressionsAleksey Kladov2020-03-111-2/+8
| | | | closes #3512
* Parse attr in rhs of let stmtsEdwin Cheng2020-02-281-1/+2
|
* Nest attrs into exprs in function argsAleksey Kladov2020-01-171-4/+1
|
* Extract expr_with_attrsAleksey Kladov2020-01-171-0/+20
|
* Merge pull request #2813 from jyn514/arg_attributesAleksey Kladov2020-01-171-0/+5
|\ | | | | Allow attributes before function arguments
| * move inline function closer to relevant codeJoshua Nelson2020-01-171-4/+4
| | | | | | | | also updates generated inline tests
| * shrink inline tesJoshua Nelson2020-01-161-9/+3
| |
| * Allow attributes before function argumentsJoshua Nelson2020-01-121-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for function calls of the form: ```rust ( #[attr(...)] 1.2, #[attr_one(...)] #[attr_two(...)] 1.5, ... etc ... ) ``` Closes https://github.com/rust-analyzer/rust-analyzer/issues/2801
* | Fix array element attribute positionEdwin Cheng2020-01-161-2/+2
|/
* Move inclusive range check to validationGeoffry Song2019-11-151-3/+0
|
* Fix parsing of "postfix" range expressions.Geoffry Song2019-11-151-30/+24
| | | | | | | | | | Right now they are handled in `postfix_dot_expr`, but that doesn't allow it to correctly handle precedence. Integrate it more tightly with the Pratt parser instead. Also includes a drive-by fix for parsing `match .. {}`. Fixes #2242.
* Merge #1951bors[bot]2019-10-081-1/+10
|\ | | | | | | | | | | | | | | | | | | | | | | | | 1951: Lower the precedence of the `as` operator. r=matklad a=goffrie Previously, the `as` operator was being parsed like a postfix expression, and therefore being given the highest possible precedence. That caused it to bind more tightly than prefix operators, which it should not. Instead, parse it somewhat like a normal binary expression with some special-casing. Fixes #1851. Co-authored-by: Geoffry Song <[email protected]>
| * Move tests aroundGeoffry Song2019-10-061-6/+5
| |
| * Lower the precedence of the `as` operator.Geoffry Song2019-10-031-2/+12
| | | | | | | | | | | | | | Previously, the `as` operator was being parsed like a postfix expression, and therefore being given the highest possible precedence. That caused it to bind more tightly than prefix operators, which it should not. Instead, parse it somewhat like a normal binary expression with some special-casing.
* | Fix parsing of block expressions in "forbid_structs" contexts.Geoffry Song2019-10-031-5/+20
|/ | | | | | Forbidding block expressions entirely is too strict; instead, we should only forbid them in contexts where we are parsing an optional RHS (i.e. the RHS of a range expression).
* Added test for check doc strings in crates.Alexander Andreev2019-09-301-0/+2
| | | | #1856
* Replace usages of bump_any with bumpkjeremy2019-09-191-10/+10
|
* cleanup dollar handling in expressionsAleksey Kladov2019-09-101-40/+9
|
* WIP: switch to fully decomposed tokens internallyAleksey Kladov2019-09-101-91/+107
|
* rename bump -> bump_anyAleksey Kladov2019-09-091-19/+19
|
* tiny simplificationAleksey Kladov2019-09-091-2/+2
|
* always wrap block into an expressionAleksey Kladov2019-09-021-0/+5
|
* rename struct -> record, pos -> tupleAleksey Kladov2019-08-231-7/+7
|
* Merge #1676bors[bot]2019-08-141-1/+1
|\ | | | | | | | | | | | | | | 1676: Fix for<'lifetime> for types specified by path r=matklad a=eupn Fixes #1467. Co-authored-by: Evgenii P <[email protected]>
| * Fix is_path_start to accept T![<], fix is_path_start usagesEvgenii P2019-08-131-1/+1
| |
* | Merge #1636bors[bot]2019-08-131-7/+12
|\ \ | |/ |/| | | | | | | | | | | 1636: fix block parse problem r=matklad a=bravomikekilo try to fix [issue-1598](https://github.com/rust-analyzer/rust-analyzer/issues/1598). Co-authored-by: bravomikekilo <[email protected]>
| * add inline testbravomikekilo2019-08-131-0/+6
| |
| * fix block parse problembravomikekilo2019-08-031-7/+6
| |
* | Move numeric names inside of `NameRef`Aleksey Kladov2019-08-091-6/+4
| |
* | Make name_ref to accept numeric names optionallyEvgenii P2019-08-091-3/+3
| |
* | Parse tuple struct field initializationEvgenii P2019-08-091-1/+2
|/
* add await to syntax, parser for await_exprUnreal Hoang2019-07-201-0/+12
|
* fixed #1384zjy2019-06-281-0/+11
|
* fix: never type with bindingcsmoe2019-06-071-1/+3
| | | | Change-Id: I14e1bc628b9d2dfdb1f40de3d3707f4e872767f2
* Fix clippy::if_same_then_elseAlan Du2019-06-041-0/+1
|
* apply T! macro where it is possibleSergey Parilin2019-05-151-78/+78
|
* Simplifykjeremy2019-04-261-6/+6
|
* Add expr, pat, ty and macro_stmtsEdwin Cheng2019-04-181-10/+34
|
* Add mbe stmt matcherEdwin Cheng2019-04-171-72/+82
|
* Fix bug and add expr , pat , ty matcherEdwin Cheng2019-04-141-9/+41
|
* Parse and infer tuple indicesrobojumper2019-04-061-1/+12
|
* Fix parsing <= in type_argsVille Penttinen2019-03-301-0/+1
|
* Replace `contract_child` to a less ad-hoc APIpcpthm2019-03-191-10/+10
|
* Error about attributes onpcpthm2019-03-191-12/+23
| | | | unallowed types of expression statement
* Allow attributes on top level expressionpcpthm2019-03-191-32/+51
| | | | | | A top level expression is either - a expression statement or - the last expression in a block