Skip to content

Commit

Permalink
std::unique_ptr is not supported in swift
Browse files Browse the repository at this point in the history
  • Loading branch information
wu-hui committed Jan 15, 2025
1 parent 71e7f57 commit a318a20
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ NS_SWIFT_NAME(CallbackWrapper)
// are invoked on a different thread than the one they were originally defined in. If this callback
// is expected to be called on a different thread, it should be marked as `Sendable` to ensure
// thread safety.
+ (std::unique_ptr<core::EventListener<std::vector<api::PipelineResult>>>)
+ (std::shared_ptr<core::EventListener<std::vector<api::PipelineResult>>>)
wrapPipelineCallback:(std::shared_ptr<api::Firestore>)firestore
completion:(void (^NS_SWIFT_SENDABLE)(
std::shared_ptr<std::vector<api::PipelineResult>> result,
Expand Down
2 changes: 1 addition & 1 deletion Firestore/core/interfaceForSwift/api/pipeline.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ class Firestore;
class PipelineResult;

using PipelineSnapshotListener =
std::unique_ptr<core::EventListener<std::vector<PipelineResult>>>;
std::shared_ptr<core::EventListener<std::vector<PipelineResult>>>;

class Pipeline {
public:
Expand Down

0 comments on commit a318a20

Please sign in to comment.