7997: fix folding range kind r=matklad a=matklad

bors r+
🤖

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
bors[bot] 2021-03-13 16:25:02 +00:00 committed by GitHub
commit d453378569
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -484,7 +484,8 @@ pub(crate) fn folding_range(
let kind = match fold.kind {
FoldKind::Comment => Some(lsp_types::FoldingRangeKind::Comment),
FoldKind::Imports => Some(lsp_types::FoldingRangeKind::Imports),
FoldKind::Mods | FoldKind::Block | FoldKind::ArgList | FoldKind::Region => None,
FoldKind::Region => Some(lsp_types::FoldingRangeKind::Region),
FoldKind::Mods | FoldKind::Block | FoldKind::ArgList => None,
};
let range = range(line_index, fold.range);