Skip to content

Instantly share code, notes, and snippets.

@stepancheg
Created May 3, 2014 20:25
Show Gist options
  • Save stepancheg/fbb607e7416f8bc17cb2 to your computer and use it in GitHub Desktop.
Save stepancheg/fbb607e7416f8bc17cb2 to your computer and use it in GitHub Desktop.
lib/descriptorx.rs:70:26: 70:71 error: cannot infer an appropriate lifetime due to conflicting requirements
lib/descriptorx.rs:70 .map(|e| EnumWithPath { path: m.to_path(), en: e })));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
lib/descriptorx.rs:70:51: 70:62 note: first, the lifetime cannot outlive the method call at 70:50...
lib/descriptorx.rs:70 .map(|e| EnumWithPath { path: m.to_path(), en: e })));
^~~~~~~~~~~
lib/descriptorx.rs:70:51: 70:52 note: ...so that method receiver is valid for the method call
lib/descriptorx.rs:70 .map(|e| EnumWithPath { path: m.to_path(), en: e })));
^
lib/descriptorx.rs:69:27: 70:72 note: but, the lifetime must be valid for the method call at 69:26...
lib/descriptorx.rs:69 .flat_map(|m| m.get_message().get_enum_type().iter()
lib/descriptorx.rs:70 .map(|e| EnumWithPath { path: m.to_path(), en: e })));
lib/descriptorx.rs:70:26: 70:71 note: ...so that argument is valid for the call
lib/descriptorx.rs:70 .map(|e| EnumWithPath { path: m.to_path(), en: e })));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment