Internal change

PiperOrigin-RevId: 490159674
This commit is contained in:
Camillo Lugaresi 2022-11-21 23:22:49 -08:00 committed by Copybara-Service
parent 7c9fc9a642
commit 54a684717f

View File

@ -31,8 +31,8 @@ class AttachmentBase {};
template <class Context, class T>
class Attachment : public AttachmentBase<Context> {
public:
using FactoryT = std::function<AttachmentPtr<T>(Context&)>;
Attachment(FactoryT factory) : factory_(factory) {}
using FactoryT = AttachmentPtr<T> (*)(Context&);
explicit constexpr Attachment(FactoryT factory) : factory_(factory) {}
Attachment(const Attachment&) = delete;
Attachment(Attachment&&) = delete;