From 1e4f54fe688ecc2e729a8f21e1da3cf739d8591a Mon Sep 17 00:00:00 2001 From: sergiotarxz Date: Tue, 2 Aug 2022 05:21:16 +0200 Subject: [PATCH] Adding std::vector storing all fakes. --- Fake.h | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Fake.h b/Fake.h index 9ceccc7..3cd2e40 100644 --- a/Fake.h +++ b/Fake.h @@ -16,6 +16,7 @@ namespace spy */ template +extern std::vector fake_list; class Fake { public: @@ -33,6 +34,7 @@ Fake(H& hook, ReturnType (*func)(ArgTypes...)) :hook_(hook) { func_ = hook_.patch(func); + fake_list.push_back(&this); } template