Commit 44dff0c
committed
Fix interface delegation to include inherited interface members
Fixes #27
- Process all inherited interfaces recursively using AllInterfaces
- Add ProcessInterfaceMembers helper to traverse interface hierarchy
- Include return type in method key to handle overloaded GetEnumerator
- Add local NuGet cache to avoid global cache issues
- Add version marker comment for debugging (YO YO YO MAMA v2)
- Update .gitignore to exclude .nuget-cache/
The fix now generates ALL interface members including those from base
interfaces. For example, IList<T> now generates:
- IList<T> members: IndexOf, Insert, RemoveAt, this[int]
- ICollection<T> members: Add, Clear, Contains, CopyTo, Remove, Count, IsReadOnly
- IEnumerable<T> members: GetEnumerator
Known limitation: IEnumerable (non-generic) GetEnumerator() requires
explicit interface implementation due to return type conflict. This
will be addressed in a future update.1 parent f758b43 commit 44dff0c
File tree
5 files changed
+126
-7
lines changed- source/timewarp-source-generators
- tests/timewarp-source-generators-test-console/generated/timewarp-source-generators/TimeWarp.SourceGenerators.InterfaceDelegationGenerator
5 files changed
+126
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
316 | 316 | | |
317 | 317 | | |
318 | 318 | | |
| 319 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
18 | 21 | | |
19 | 22 | | |
20 | 23 | | |
| |||
Lines changed: 51 additions & 6 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
267 | 267 | | |
268 | 268 | | |
269 | 269 | | |
| 270 | + | |
270 | 271 | | |
271 | | - | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
272 | 305 | | |
273 | 306 | | |
274 | 307 | | |
275 | 308 | | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
276 | 323 | | |
277 | 324 | | |
278 | 325 | | |
| |||
282 | 329 | | |
283 | 330 | | |
284 | 331 | | |
285 | | - | |
286 | | - | |
| 332 | + | |
| 333 | + | |
287 | 334 | | |
288 | 335 | | |
289 | 336 | | |
| |||
295 | 342 | | |
296 | 343 | | |
297 | 344 | | |
298 | | - | |
299 | | - | |
300 | 345 | | |
301 | 346 | | |
302 | 347 | | |
| |||
375 | 420 | | |
376 | 421 | | |
377 | 422 | | |
378 | | - | |
| 423 | + | |
379 | 424 | | |
380 | 425 | | |
381 | 426 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
6 | | - | |
| 6 | + | |
7 | 7 | | |
8 | 8 | | |
9 | 9 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
0 commit comments