File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -1816,7 +1816,7 @@ impl Symbol {
18161816 true => symbol. borrow ( ) . range ( ) . start ( ) . to_u32 ( ) ,
18171817 false => symbol. borrow ( ) . body_range ( ) . start ( ) . to_u32 ( ) ,
18181818 } ;
1819- if range < offset && symbol. borrow ( ) . body_range ( ) . end ( ) . to_u32 ( ) > offset {
1819+ if range <= offset && symbol. borrow ( ) . body_range ( ) . end ( ) . to_u32 ( ) > offset {
18201820 result = Symbol :: get_scope_symbol ( symbol. clone ( ) , offset, is_param) ;
18211821 }
18221822 } ,
@@ -1825,7 +1825,7 @@ impl Symbol {
18251825 true => symbol. borrow ( ) . range ( ) . start ( ) . to_u32 ( ) ,
18261826 false => symbol. borrow ( ) . body_range ( ) . start ( ) . to_u32 ( ) ,
18271827 } ;
1828- if range < offset && symbol. borrow ( ) . body_range ( ) . end ( ) . to_u32 ( ) > offset {
1828+ if range <= offset && symbol. borrow ( ) . body_range ( ) . end ( ) . to_u32 ( ) > offset {
18291829 result = Symbol :: get_scope_symbol ( symbol. clone ( ) , offset, is_param) ;
18301830 }
18311831 }
Original file line number Diff line number Diff line change @@ -66,7 +66,7 @@ macro_rules! impl_section_mgr_for {
6666 fn get_section_for( & self , position: u32 ) -> SectionRange {
6767 let mut last_section = self . sections. last( ) . unwrap( ) ;
6868 for section in self . sections. iter( ) . rev( ) . skip( 1 ) { //reverse to fasten most calls as they will be with TextSize::MAX
69- if section. start < position {
69+ if section. start <= position {
7070 break ;
7171 }
7272 last_section = section;
You can’t perform that action at this time.
0 commit comments