diff options
author | Benjamin Coenen <[email protected]> | 2020-05-06 08:57:00 +0100 |
---|---|---|
committer | Benjamin Coenen <[email protected]> | 2020-05-06 08:57:00 +0100 |
commit | c4d128e454448191c4b21d8e151c673e4c42376e (patch) | |
tree | 17cf5bbf429642c52708cd0d3c1d8885b63543f0 /crates/ra_ide/src/source_change.rs | |
parent | 0bf02f5ccac99c91f10ef46bb06ff2ea316c382c (diff) | |
parent | 30eb458b4fa8adcecd8cbf731bd1cfa9a7a8b88b (diff) |
Merge branch 'master' of github.com:rust-analyzer/rust-analyzer into fix_4311
Diffstat (limited to 'crates/ra_ide/src/source_change.rs')
-rw-r--r-- | crates/ra_ide/src/source_change.rs | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/crates/ra_ide/src/source_change.rs b/crates/ra_ide/src/source_change.rs index 71b0e8f75..10afd7825 100644 --- a/crates/ra_ide/src/source_change.rs +++ b/crates/ra_ide/src/source_change.rs | |||
@@ -35,8 +35,10 @@ impl SourceChange { | |||
35 | /// Creates a new SourceChange with the given label, | 35 | /// Creates a new SourceChange with the given label, |
36 | /// containing only the given `SourceFileEdits`. | 36 | /// containing only the given `SourceFileEdits`. |
37 | pub(crate) fn source_file_edits<L: Into<String>>(label: L, edits: Vec<SourceFileEdit>) -> Self { | 37 | pub(crate) fn source_file_edits<L: Into<String>>(label: L, edits: Vec<SourceFileEdit>) -> Self { |
38 | let label = label.into(); | ||
39 | assert!(label.starts_with(char::is_uppercase)); | ||
38 | SourceChange { | 40 | SourceChange { |
39 | label: label.into(), | 41 | label: label, |
40 | source_file_edits: edits, | 42 | source_file_edits: edits, |
41 | file_system_edits: vec![], | 43 | file_system_edits: vec![], |
42 | cursor_position: None, | 44 | cursor_position: None, |