aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
...
| * | fix typoAleksey Kladov2019-04-111-6/+6
|/ /
* | Merge #1131bors[bot]2019-04-1010-180/+136
|\ \ | | | | | | | | | | | | | | | | | | | | | 1131: Use inline snapshots in complete_dot r=matklad a=vipentti Relates to #1127 Co-authored-by: Ville Penttinen <[email protected]>
| * | Use inline snapshots in complete_dotVille Penttinen2019-04-1010-180/+136
| | |
* | | Merge #1130bors[bot]2019-04-104-72/+58
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | 1130: Use inline snapshots in complete_fn_param r=matklad a=vipentti Relates to #1127 Co-authored-by: Ville Penttinen <[email protected]>
| * | Use inline snapshots in complete_fn_paramVille Penttinen2019-04-104-72/+58
|/ /
* | Merge #1128bors[bot]2019-04-1012-74/+85
|\ \ | | | | | | | | | | | | | | | | | | | | | 1128: A touch of type-safety r=matklad a=matklad Note that we intentionally don't use `Either` from crates.io: I like A/B naming more then left/rigth, I feel like we might need Either3 with C at some point, and I'd love the ability to write inherent impls Co-authored-by: Aleksey Kladov <[email protected]>
| * | type-safer source-map for bindingsAleksey Kladov2019-04-107-30/+45
| | |
| * | use either for usesAleksey Kladov2019-04-106-44/+40
|/ /
* | Merge #1126bors[bot]2019-04-0910-219/+110
|\ \ | | | | | | | | | | | | | | | | | | | | | 1126: Swithc to native salsa interning r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
| * | drop old interning infraAleksey Kladov2019-04-092-108/+1
| | |
| * | migrate to salsas interningAleksey Kladov2019-04-098-111/+109
| | |
* | | Merge #1122bors[bot]2019-04-093-1/+126
|\ \ \ | |/ / |/| | | | | | | | | | | | | | | | | | | | | | | | | | 1122: Add explicit type assist. r=matklad a=marcogroppo This assist can be used to specify the explicit type in let statements. For example `let num = 1;` becomes `let num: i32 = 1;`. The assist is applicable only if the inferred type is fully known. Co-authored-by: Marco Groppo <[email protected]>
| * | Stylistic changes. Updated features.md with the new assists.Marco Groppo2019-04-092-9/+37
| | |
| * | Add explicit type assist.Marco Groppo2019-04-082-0/+97
| |/
* | Merge #1110bors[bot]2019-04-0916-231/+391
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1110: Introduce display module and implement new FunctionSignature for CallInfo's r=matklad a=vipentti This introduces a new module `display` in `ra_ide_api` that contains UI-related things, in addition this refactors CallInfo's function signatures into a new `FunctionSignature` type, which implements `Display` and can be converted into `lsp_types::SignatureInformation` in the `conv` layer. Currently only `CallInfo` uses the `FunctionSignature` directly, but `function_label` now uses the same signature and returns it as a string, using the `Display` implementation. This also fixes #960 I think this similar structure could be applied to other UI-displayable items, so instead of the `ra_ide_api` returning `Strings` we could return some intermediate structures that can be converted into a UI-displayable `String` easily, but that could also provide some additional information. Co-authored-by: Ville Penttinen <[email protected]>
| * | Fix doc commentVille Penttinen2019-04-091-1/+1
| | |
| * | Move display related things from hover to displayVille Penttinen2019-04-093-109/+110
| | |
| * | Move FunctionSignature to display/function_signatureVille Penttinen2019-04-092-100/+104
| | |
| * | Make display modules privateVille Penttinen2019-04-092-5/+6
| | |
| * | Move structure to display/structureVille Penttinen2019-04-094-9/+9
| | |
| * | Move navigation_target to display/navigation_targetVille Penttinen2019-04-094-4/+6
| | |
| * | Move completion label functions to displayVille Penttinen2019-04-094-31/+32
| | |
| * | Add FunctionSignature::from_hirVille Penttinen2019-04-092-6/+11
| | |
| * | Normalize line-endings in display.rsVille Penttinen2019-04-091-112/+112
| | | | | | | | | | | | This changes from CRLF to LF
| * | Move FunctionSignature creation to displayVille Penttinen2019-04-093-50/+54
| | |
| * | Add no parameter test to call_infoVille Penttinen2019-04-091-0/+19
| | |
| * | Move FunctionSignature to display, remove write_joinedVille Penttinen2019-04-092-49/+36
| | | | | | | | | | | | | | | write_joined is replaced with `join_to_string::join` which provides the necessary functionality.
| * | Move test specific thingsVille Penttinen2019-04-092-16/+11
| | |
| * | Update test snapshotsVille Penttinen2019-04-092-10/+10
| | |
| * | Refactor CallInfo function signatures to new FunctionSignature typeVille Penttinen2019-04-098-69/+210
|/ / | | | | | | | | This is used by CallInfo to create a pretty printed function signature that can be used with completions and other places as well.
* | Merge #1123bors[bot]2019-04-0910-158/+192
|\ \ | |/ |/| | | | | | | | | | | 1123: migrate to untyped rowan r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
| * migrate to untyped rowanAleksey Kladov2019-04-0910-158/+192
|/
* Merge #1105bors[bot]2019-04-088-231/+683
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1105: [WIP] Implement ra_mbe meta variables support r=matklad a=edwin0cheng This PR implements the following meta variable support in `ra_mba` crate (issue #720): - [x] `path` - [ ] `expr` - [ ] `ty` - [ ] `pat` - [ ] `stmt` - [ ] `block` - [ ] `meta` - [ ] `item` *Implementation Details* In the macro expanding lhs phase, if we see a meta variable type, we try to create a `tt:TokenTree` from the remaining input. And then we use a special set of `ra_parser` to parse it to `SyntaxNode`. Co-authored-by: Edwin Cheng <[email protected]>
| * Refactoring and add some docsEdwin Cheng2019-04-082-83/+106
| |
| * Fixed infintite loop bugEdwin Cheng2019-04-081-30/+4
| |
| * Fixed empty node bugEdwin Cheng2019-04-081-10/+49
| |
| * Use SubtreeWalker instread of flatten TtTokenEdwin Cheng2019-04-084-258/+421
| |
| * Combine all tokensource to one and refactoringEdwin Cheng2019-04-075-86/+94
| |
| * Refactoring subtree_sourceEdwin Cheng2019-04-074-364/+386
| |
| * Add TtCursorTokenSource and TtCursorTokenSinkEdwin Cheng2019-04-064-24/+216
| |
| * Add path test and empty eat_path handlingEdwin Cheng2019-04-063-0/+31
| |
* | Merge #1121bors[bot]2019-04-081-2/+2
|\ \ | | | | | | | | | | | | | | | | | | | | | 1121: Avoid two-phase borrow conflict r=matklad a=lnicola See https://github.com/rust-lang/rust/issues/59159. Co-authored-by: LaurenČ›iu Nicola <[email protected]>
| * | Avoid two-phase borrow conflictLaurențiu Nicola2019-04-081-2/+2
|/ /
* | Merge #1103bors[bot]2019-04-076-55/+124
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1103: Array inference r=flodiebold a=Lapz Fixes the final item in #394. The only problem is that infering the repeat cause some types to be infered twices. i.e ```rust fn test() { let y = unknown; [y, &y]; } ``` results in the following diff: ```diff [11; 48) '{ ...&y]; }': () [21; 22) 'y': &{unknown} [25; 32) 'unknown': &{unknown} -[38; 45) '[y, &y]': [&&{unknown}] +[38; 45) '[y, &y]': [&&{unknown};usize] [39; 40) 'y': &{unknown} +[39; 40) 'y': &{unknown} [42; 44) '&y': &&{unknown} [43; 44) 'y': &{unknown} ``` Should the code produce two inference results for 'y' and if not could any tell me what needs to change. Co-authored-by: Lenard Pratt <[email protected]>
| * | updated snapshotsLenard Pratt2019-04-076-77/+44
| | |
| * | Added ArrayExprKind,Lenard Pratt2019-04-075-31/+76
| | | | | | | | | | | | | | | changed the display for fixed array types, Added Array Enum to ra_hir/expr
| * | Added inference of array lengthLenard Pratt2019-04-076-5/+62
|/ /
* | Merge #1119bors[bot]2019-04-071-6/+10
|\ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1119: Add warning when open file outside workspace r=matklad a=edwin0cheng When file is not found in `ra_vfs` but exist, use `LspError` for warning instead of `error_fmt` to bail out error, Temporarily fix #967 . edit: typo Co-authored-by: Edwin Cheng <[email protected]>
| * | Remove checking file existsEdwin Cheng2019-04-071-13/+6
| | |
| * | fix formattingEdwin Cheng2019-04-071-1/+2
| | |