Commit 6bd91b2
authored
Structure highlighting bug fixes (#1061)
* Don't ask for line information past EOF.
Closes #1060
Can be reproduced with `if True:pass` at EOF and, importantly, outside
the viewport (so prepended with blank lines, for example).
I'm not sure our behaviour in this scenario makes sense but this change
at least makes it safe.
* Detect the `if True:pass` case consistently.
Use a simpler approach to test if we're the same line to make it easier
to follow.1 parent 9d066cf commit 6bd91b2
1 file changed
+22
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
86 | 86 | | |
87 | 87 | | |
88 | 88 | | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
89 | 99 | | |
90 | 100 | | |
91 | 101 | | |
92 | 102 | | |
93 | 103 | | |
94 | | - | |
| 104 | + | |
95 | 105 | | |
96 | 106 | | |
97 | 107 | | |
98 | 108 | | |
99 | | - | |
100 | 109 | | |
101 | | - | |
102 | | - | |
103 | | - | |
104 | | - | |
105 | | - | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
106 | 119 | | |
107 | 120 | | |
108 | 121 | | |
| |||
179 | 192 | | |
180 | 193 | | |
181 | 194 | | |
182 | | - | |
| 195 | + | |
183 | 196 | | |
184 | 197 | | |
185 | 198 | | |
186 | 199 | | |
187 | 200 | | |
188 | 201 | | |
189 | | - | |
| 202 | + | |
190 | 203 | | |
191 | 204 | | |
192 | 205 | | |
| |||
0 commit comments