7 ms·
Could you elaborate? I find this unintuitive.
by andyferris 3y ago
Could you elaborate? I find this unintuitive.
- csjh 3y agoSince static lifetimes last for the entirety of the program, it can sub in for any other lifetime (as it is guaranteed to exist until the end of the other lifetime)
- raincole 3y agoI am not familiar with the formal type theory, but this one is intuitive if you view it this way: 1. When A is a subtype of B, it means A can be used as B (a Teacher can be used by any function that accepts a Human). 2. static lifetime lives longer any other lifetimes, so it can be used as other lifetimes.