Skip to content

Commit 676988b

Browse files
authored
Talk more about runtime calls
1 parent 55f6739 commit 676988b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

const-generic-const-fn-bounds.md

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,8 @@ and `const` modifiers on `impl` blocks.
211211
# Unresolved questions
212212
[unresolved-questions]: #unresolved-questions
213213

214+
## Runtime uses don't have `const` restrictions?
215+
214216
Should `impl const` blocks additionally generate impls that are not const if any generic
215217
parameters are not const?
216218

@@ -224,7 +226,7 @@ impl<T: Add> const Add for Foo<T> {
224226
}
225227
```
226228

227-
would allow calling `Foo(String::new()) + Foo(String::new())` even though that is (at the time
229+
would allow calling `Foo(String::from("foo")) + Foo(String::from("bar"))` even though that is (at the time
228230
of writing this RFC) most definitely not const, because `String` only has an `impl Add for String`
229231
and not an `impl const Add for String`.
230232

0 commit comments

Comments
 (0)