From 833a06e36c77bbbf21468e41451609ddf26d46ea Mon Sep 17 00:00:00 2001 From: Divy Srivastava Date: Thu, 2 Jan 2025 20:56:59 -0800 Subject: [PATCH] Fix accessors fast call error (#1022) --- ops/op2/mod.rs | 2 +- testing/checkin/runner/ops.rs | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ops/op2/mod.rs b/ops/op2/mod.rs index bead5c8d5..11750a900 100644 --- a/ops/op2/mod.rs +++ b/ops/op2/mod.rs @@ -254,7 +254,7 @@ pub(crate) fn generate_op2( } } None => { - if config.fast || config.getter || config.setter { + if config.fast { return Err(Op2Error::ShouldNotBeFast("fast")); } if config.nofast { diff --git a/testing/checkin/runner/ops.rs b/testing/checkin/runner/ops.rs index 8fd9c4ecd..6c4d52120 100644 --- a/testing/checkin/runner/ops.rs +++ b/testing/checkin/runner/ops.rs @@ -101,6 +101,12 @@ impl TestObjectWrap { tokio::time::sleep(std::time::Duration::from_millis(ms as u64)).await; Ok(()) } + + #[getter] + #[string] + fn with_slow_getter(&self) -> String { + String::from("getter") + } } pub struct DOMPoint {