Skip to content

Commit 4956358

Browse files
committed
Fix example so it would actually compile
1 parent bad849f commit 4956358

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

const-generic-const-fn-bounds.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ You can call methods of generic parameters of a const function, because they are
2727
with that bound.
2828

2929
```rust
30-
const fn triple_add<T: Add>(a: T, b: T, c: T) -> T {
30+
const fn triple_add<T: Add<Output=T>>(a: T, b: T, c: T) -> T {
3131
a + b + c
3232
}
3333
```

0 commit comments

Comments
 (0)