Skip to content

Commit

Permalink
Syntax highlight and note about current rust in infer docs
Browse files Browse the repository at this point in the history
  • Loading branch information
bjorn3 committed Feb 28, 2017
1 parent be49671 commit 90e94d9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/librustc/infer/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ course, it depends on the program.

The main case which fails today that I would like to support is:

```text
```rust
fn foo<T>(x: T, y: T) { ... }

fn bar() {
Expand All @@ -168,6 +168,8 @@ because the type variable `T` is merged with the type variable for
`X`, and thus inherits its UB/LB of `@mut int`. This leaves no
flexibility for `T` to later adjust to accommodate `@int`.

Note: `@` and `@mut` are replaced with `Rc<T>` and `Rc<RefCell<T>>` in current Rust.

### What to do when not all bounds are present

In the prior discussion we assumed that A.ub was not top and B.lb was
Expand Down

0 comments on commit 90e94d9

Please sign in to comment.