Skip to content

Instantly share code, notes, and snippets.

@eholk
Created October 22, 2013 15:21
Show Gist options
  • Select an option

  • Save eholk/7102595 to your computer and use it in GitHub Desktop.

Select an option

Save eholk/7102595 to your computer and use it in GitHub Desktop.
make
rustc --lib -O scirust.rs
matrix/matrix.rs:265:54: 266:9 error: cannot infer an appropriate lifetime due to conflicting requirements
matrix/matrix.rs:265 i: i, j: j, rows: rows, cols: cols, base: self
matrix/matrix.rs:266 }
matrix/matrix.rs:257:72: 267:5 note: first, the lifetime cannot outlive the anonymous lifetime #1 defined on the block at 257:72...
matrix/matrix.rs:257 -> SubMatrix_t<'self, T, TransposeMatrix<'self, T, M>> {
matrix/matrix.rs:258 assert!(rows > 0);
matrix/matrix.rs:259 assert!(cols > 0);
matrix/matrix.rs:260 assert!(i < self.num_rows());
matrix/matrix.rs:261 assert!(j < self.num_cols());
matrix/matrix.rs:262 assert!(i + rows <= self.num_rows());
...
matrix/matrix.rs:265:54: 266:9 note: ...due to the following expression
matrix/matrix.rs:265 i: i, j: j, rows: rows, cols: cols, base: self
matrix/matrix.rs:266 }
matrix/matrix.rs:257:72: 267:5 note: but, the lifetime must be valid for the lifetime &'self as defined on the block at 257:72...
matrix/matrix.rs:257 -> SubMatrix_t<'self, T, TransposeMatrix<'self, T, M>> {
matrix/matrix.rs:258 assert!(rows > 0);
matrix/matrix.rs:259 assert!(cols > 0);
matrix/matrix.rs:260 assert!(i < self.num_rows());
matrix/matrix.rs:261 assert!(j < self.num_cols());
matrix/matrix.rs:262 assert!(i + rows <= self.num_rows());
...
matrix/matrix.rs:264:8: 264:19 note: ...due to the following expression
matrix/matrix.rs:264 SubMatrix_t {
^~~~~~~~~~~
error: aborting due to previous error
task '<unnamed>' failed at 'explicit failure', /home/eric/projects/mozilla/rust/src/libsyntax/diagnostic.rs:98
task '<unnamed>' failed at 'explicit failure', /home/eric/projects/mozilla/rust/src/librustc/rustc.rs:395
make: *** [libSciRust] Error 101
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment