diff --git a/src/pvxs/data.h b/src/pvxs/data.h index 16e41c9..2a73fa4 100644 --- a/src/pvxs/data.h +++ b/src/pvxs/data.h @@ -52,7 +52,9 @@ struct FieldDesc; //! store_t shall be convertible to/from T through StoreTransform::in() and out(). //! StorageMap::code is the associated StoreType. template -struct StorageMap; +struct StorageMap { + typedef void not_storable; +}; // map signed integers to int64_t template @@ -629,7 +631,7 @@ public: //! If possible, this value is cast to T and passed as the only argument //! of the provided function. template - void as(FN&& fn) const { + typename impl::StorageMap::type>::not_storable as(FN&& fn) const { typename impl::StoreAs::store_t val; if(tryCopyOut(&val, impl::StoreAs::code)) { fn(impl::StoreTransform::out(val));