Skip to content

Commit 84a4b32

Browse files
committed
Lifetime inference test case improvements.
Cleanup the tests so we can cross reference them with the documentation. Update the tests to allow multiple annotations and defaults.
1 parent bbdadac commit 84a4b32

File tree

3 files changed

+595
-231
lines changed

3 files changed

+595
-231
lines changed

docs/ReferenceGuides/LifetimeAnnotation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@ Given a function or method that returns a non-Escapable result:
2828

2929
- Default to `@_lifetime(<scope> self)` for a `~Escapable` result on methods with no parameters.
3030

31-
| Type of parameter | default |
31+
| Type of parameter | default |
3232
| (`a` or `self`) | lifetime dependency |
33-
| ----------------- | ------------------------------ |
33+
| ----------------- | ------------------------------ |
3434
| `Escapable` | `@_lifetime(borrow param)`[^1] |
3535
| `inout Escapable` | `@_lifetime(&param)`[^1] |
3636
| `~Escapable` | none[^2] |

0 commit comments

Comments
 (0)