mago 1.26.0

A comprehensive suite of PHP tooling inspired by Rust’s approach, providing parsing, linting, formatting, and more through a unified CLI and library interface.
1
2
3
4
5
6
7
8
9
10
//! `textDocument/foldingRange`. Reads pre-computed fold ranges from the
//! file's [`super::super::file_analysis::FileAnalysis`].

use tower_lsp::lsp_types::FoldingRange;

use crate::language_server::file_analysis::FileAnalysis;

pub fn compute(analysis: &FileAnalysis) -> Vec<FoldingRange> {
    analysis.fold_ranges.clone()
}