4 ms·
Context.Value's signature is Value(any) any - you have to use type conversion or reflection to determine the value's type at runtime, instead of a compile-time
by haiku2077 1y ago
Context.Value's signature is Value(any) any - you have to use type conversion or reflection to determine the value's type at runtime, instead of a compile-time check.
- the_mitsuhiko 1y agoBut I have methods such as MustRateLimiterFromContext(ctx) which returns the right type :)
- haiku2077 1y agoBy crashing your program at runtime if any wrong type is added!