Skip to content

Commit

Permalink
Rollup merge of rust-lang#44464 - Dushistov:master, r=alexcrichton
Browse files Browse the repository at this point in the history
add test for rust-lang#41229

Closes rust-lang#41229
  • Loading branch information
GuillaumeGomez authored Sep 10, 2017
2 parents 329ed4a + 4928d25 commit dcc1d14
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/test/compile-fail/issue-41229-ref-str.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
// Copyright 2017 The Rust Project Developers. See the COPYRIGHT
// file at the top-level directory of this distribution and at
// http://rust-lang.org/COPYRIGHT.
//
// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
// option. This file may not be copied, modified, or distributed
// except according to those terms.

pub fn example(ref s: str) {}
//~^ ERROR the trait bound `str: std::marker::Sized` is not satisfied
//~| `str` does not have a constant size known at compile-time
//~| the trait `std::marker::Sized` is not implemented for `str`

fn main() {}

0 comments on commit dcc1d14

Please sign in to comment.