Skip to content

Commit

Permalink
Disable deprecated compiler warnings on GCC & Clang
Browse files Browse the repository at this point in the history
Destroyable is deprecated but, here we're just testing it.
  • Loading branch information
anjohnson committed Aug 7, 2024
1 parent d5671b0 commit 19475e9
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions testApp/check_consist.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,14 @@ namespace pvd = epics::pvData;
namespace pva = epics::pvAccess;

namespace {
#pragma GCC diagnostic push
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
struct Destroyer {
pvd::Destroyable::shared_pointer D;
Destroyer(const pvd::Destroyable::shared_pointer& d) : D(d) {}
~Destroyer() { if(D) D->destroy(); }
};
#pragma GCC diagnostic pop

struct Releaser {
pva::Monitor::shared_pointer& mon;
Expand Down

0 comments on commit 19475e9

Please sign in to comment.