-
Notifications
You must be signed in to change notification settings - Fork 13.7k
Closed
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)NLL-completeWorking towards the "valid code works" goalWorking towards the "valid code works" goal
Milestone
Description
Both webrender and piston-image are failing; errors are included below. I can provide more information if necessary.
For the time being I've disabled NLL on these two benchmarks -- once this issue is closed I'll re-enable it.
error[E0502]: cannot borrow `_` as mutable because it is also borrowed as immutable
--> webrender/src/display_list_flattener.rs:850:37
|
849 | match self.hit_testing_runs.last_mut() {
| _________-
| |_________|
| ||
850 | || Some(&mut HitTestingRun(ref mut items, prev_clip_and_scroll))
| || ^^^^^^^^^^^^^ mutable borrow occurs here
851 | || if prev_clip_and_scroll == clip_and_scroll => {
852 | || items.push(new_item);
... ||
855 | || _ => {}
856 | || }
| || -
| ||_________|
| |__________immutable borrow occurs here
| borrow later used here
warning: variable does not need to be mutable
--> webrender/src/glyph_rasterizer/no_pathfinder.rs:61:33
|
61 | Entry::Occupied(mut entry) => {
| ----^^^^^
| |
| help: remove this `mut`
warning: variable does not need to be mutable
--> webrender/src/render_backend.rs:713:41
|
713 | if let Some(mut built_scene) = built_scene.take() {
| ----^^^^^^^^^^^
| |
| help: remove this `mut`
warning: variable does not need to be mutable
--> webrender/src/renderer.rs:1809:21
|
1809 | mut doc,
| ----^^^
| |
| help: remove this `mut`
error: aborting due to previous error
For more information about this error, try `rustc --explain E0502`.
error[E0502]: cannot borrow `_` as mutable because it is also borrowed as immutable
--> src/tiff/decoder/mod.rs:425:53
|
404 | Ok(match (color_type, buffer) {
| ____________-
| |____________|
| ||
405 | || (ColorType:: RGB(8), DecodingBuffer::U8(ref mut buffer)) |
406 | || (ColorType::RGBA(8), DecodingBuffer::U8(ref mut buffer)) => {
407 | || try!(reader.read(&mut buffer[..bytes]))
... ||
425 | || (ColorType::Gray(n), DecodingBuffer::U8(ref mut buffer)) if n <= 8 => {
| || ^^^^^^^^^^^^^^ mutable borrow occurs here
... ||
436 | || )))
437 | || })
| || -
| ||_________|
| |__________immutable borrow occurs here
| borrow later used here
warning: variable does not need to be mutable
--> src/buffer.rs:596:14
|
596 | for (mut to, from) in buffer.pixels_mut().zip(self.pixels()) {
| ----^^
| |
| help: remove this `mut`
|
= note: #[warn(unused_mut)] on by default
error: aborting due to previous error
For more information about this error, try `rustc --explain E0502`.
Metadata
Metadata
Assignees
Labels
A-NLLArea: Non-lexical lifetimes (NLL)Area: Non-lexical lifetimes (NLL)NLL-completeWorking towards the "valid code works" goalWorking towards the "valid code works" goal