Commit fb42402
yeast: Delete the
The trait had a single implementor (`AstCursor`), three type parameters
of which one (`T`) was never used in any method signature, and one
external consumer that needed `use yeast::Cursor;` in scope just to
call methods on the cursor. The abstraction was overhead without a
second implementor to justify it.
Move the six trait methods to an inherent `impl AstCursor` block;
delete `shared/yeast/src/cursor.rs`, the `pub mod cursor;` and
`pub use cursor::Cursor;` lines in `lib.rs`, and the `use yeast::Cursor;`
in `tree-sitter-extractor`'s `traverse_yeast`.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>Cursor trait, inline its methods on AstCursor
1 parent bda8e7d commit fb42402
3 files changed
Lines changed: 26 additions & 38 deletions
File tree
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
882 | 882 | | |
883 | 883 | | |
884 | 884 | | |
885 | | - | |
886 | 885 | | |
887 | 886 | | |
888 | 887 | | |
| |||
This file was deleted.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
10 | | - | |
11 | 10 | | |
12 | 11 | | |
13 | 12 | | |
| |||
19 | 18 | | |
20 | 19 | | |
21 | 20 | | |
22 | | - | |
23 | 21 | | |
24 | 22 | | |
25 | 23 | | |
| |||
174 | 172 | | |
175 | 173 | | |
176 | 174 | | |
177 | | - | |
178 | | - | |
179 | | - | |
180 | | - | |
181 | | - | |
182 | | - | |
183 | | - | |
184 | | - | |
185 | | - | |
186 | | - | |
187 | | - | |
188 | | - | |
189 | | - | |
190 | | - | |
191 | | - | |
192 | | - | |
193 | | - | |
194 | | - | |
195 | | - | |
196 | | - | |
197 | | - | |
198 | | - | |
| 175 | + | |
199 | 176 | | |
200 | 177 | | |
201 | 178 | | |
202 | | - | |
| 179 | + | |
203 | 180 | | |
204 | 181 | | |
205 | 182 | | |
206 | 183 | | |
207 | | - | |
| 184 | + | |
208 | 185 | | |
209 | 186 | | |
210 | 187 | | |
| |||
213 | 190 | | |
214 | 191 | | |
215 | 192 | | |
216 | | - | |
| 193 | + | |
217 | 194 | | |
218 | 195 | | |
219 | 196 | | |
220 | | - | |
| 197 | + | |
221 | 198 | | |
222 | 199 | | |
223 | 200 | | |
224 | | - | |
| 201 | + | |
225 | 202 | | |
226 | 203 | | |
| 204 | + | |
| 205 | + | |
| 206 | + | |
| 207 | + | |
| 208 | + | |
| 209 | + | |
| 210 | + | |
| 211 | + | |
| 212 | + | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
227 | 224 | | |
228 | 225 | | |
229 | 226 | | |
| |||
0 commit comments