Advertisement
Guest User

Untitled

a guest
Sep 7th, 2024
14
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.69 KB | None | 0 0
  1. error[E0277]: the trait bound `dyn for<'a> Fn(&'a revm::revm_primitives::Env) -> std::result::Result<u64, EVMError<std::string::String>>: Ungil` is not satisfied in `{closure@src/dummy.rs:14:22: 14:29}`
  2. --> src/dummy.rs:14:22
  3. |
  4. 14 | py.allow_threads(move || {
  5. | ------------- ^------
  6. | | |
  7. | ________|_____________within this `{closure@src/dummy.rs:14:22: 14:29}`
  8. | | |
  9. | | required by a bound introduced by this call
  10. 15 | | evm.transact()
  11. 16 | | });
  12. | |_____^ within `{closure@src/dummy.rs:14:22: 14:29}`, the trait `Ungil` is not implemented for `dyn for<'a> Fn(&'a revm::revm_primitives::Env) -> std::result::Result<u64, EVMError<std::string::String>>`, which is required by `{closure@src/dummy.rs:14:22: 14:29}: Ungil`
  13. |
  14. note: required because it appears within the type `alloc::sync::ArcInner<dyn for<'a> Fn(&'a revm::revm_primitives::Env) -> std::result::Result<u64, EVMError<std::string::String>>>`
  15. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/alloc/src/sync.rs:348:8
  16. |
  17. 348 | struct ArcInner<T: ?Sized> {
  18. | ^^^^^^^^
  19. note: required because it appears within the type `PhantomData<ArcInner<dyn Fn(&Env) -> Result<u64, EVMError<String>>>>`
  20. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/core/src/marker.rs:741:12
  21. |
  22. 741 | pub struct PhantomData<T: ?Sized>;
  23. | ^^^^^^^^^^^
  24. note: required because it appears within the type `Arc<dyn for<'a> Fn(&'a revm::revm_primitives::Env) -> std::result::Result<u64, EVMError<std::string::String>>>`
  25. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/alloc/src/sync.rs:240:12
  26. |
  27. 240 | pub struct Arc<
  28. | ^^^
  29. note: required because it appears within the type `ValidationHandler<'_, (), DB>`
  30. --> /Users/michal/.cargo/registry/src/index.crates.io-6f17d22bba15001f/revm-12.1.0/src/handler/handle_types/validation.rs:22:12
  31. |
  32. 22 | pub struct ValidationHandler<'a, EXT, DB: Database> {
  33. | ^^^^^^^^^^^^^^^^^
  34. note: required because it appears within the type `Handler<'_, revm::Context<(), DB>, (), DB>`
  35. --> /Users/michal/.cargo/registry/src/index.crates.io-6f17d22bba15001f/revm-12.1.0/src/handler.rs:24:12
  36. |
  37. 24 | pub struct Handler<'a, H: Host + 'a, EXT, DB: Database> {
  38. | ^^^^^^^
  39. note: required because it appears within the type `Evm<'_, (), DB>`
  40. --> /Users/michal/.cargo/registry/src/index.crates.io-6f17d22bba15001f/revm-12.1.0/src/evm.rs:22:12
  41. |
  42. 22 | pub struct Evm<'a, EXT, DB: Database> {
  43. | ^^^
  44. note: required because it appears within the type `UnsafeCell<Evm<'_, (), DB>>`
  45. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/core/src/cell.rs:2058:12
  46. |
  47. 2058 | pub struct UnsafeCell<T: ?Sized> {
  48. | ^^^^^^^^^^
  49. note: required because it appears within the type `std::sync::Mutex<Evm<'_, (), DB>>`
  50. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/sync/mutex.rs:178:12
  51. |
  52. 178 | pub struct Mutex<T: ?Sized> {
  53. | ^^^^^
  54. = note: required because it appears within the type `&std::sync::Mutex<Evm<'_, (), DB>>`
  55. note: required because it appears within the type `std::sync::MutexGuard<'_, Evm<'_, (), DB>>`
  56. --> /Users/michal/.rustup/toolchains/nightly-aarch64-apple-darwin/lib/rustlib/src/rust/library/std/src/sync/mutex.rs:209:12
  57. |
  58. 209 | pub struct MutexGuard<'a, T: ?Sized + 'a> {
  59. | ^^^^^^^^^^
  60. note: required because it's used within this closure
  61. --> src/dummy.rs:14:22
  62. |
  63. 14 | py.allow_threads(move || {
  64. | ^^^^^^^
  65. note: required by a bound in `pyo3::Python::<'py>::allow_threads`
  66. --> /Users/michal/.cargo/registry/src/index.crates.io-6f17d22bba15001f/pyo3-0.21.2/src/marker.rs:544:12
  67. |
  68. 542 | pub fn allow_threads<T, F>(self, f: F) -> T
  69. | ------------- required by a bound in this associated function
  70. 543 | where
  71. 544 | F: Ungil + FnOnce() -> T,
  72. | ^^^^^ required by this bound in `Python::<'py>::allow_threads`
  73. = note: the full name for the type has been written to '/Users/michal/git/wake-rust/target/debug/deps/wakers-041ff76975a61328.long-type-11614340160126360247.txt'
  74. = note: consider using `--verbose` to print the full type name to the console
  75. help: use parentheses to call this trait object
  76. |
  77. 16 | }(/* &revm::revm_primitives::Env */));
  78. | +++++++++++++++++++++++++++++++++++
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement