Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: Antoine Pitrou <pitrou@free.fr>
  • Loading branch information
rok and pitrou authored Sep 25, 2024
1 parent fdf8fb6 commit 99d8ca7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions cpp/src/arrow/extension/json.cc
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ bool JsonExtensionType::ExtensionEquals(const ExtensionType& other) const {

Result<std::shared_ptr<DataType>> JsonExtensionType::Deserialize(
std::shared_ptr<DataType> storage_type, const std::string& serialized) const {
return JsonExtensionType::Make(storage_type);
return JsonExtensionType::Make(std::move(storage_type));
}

std::string JsonExtensionType::Serialize() const { return ""; }
Expand All @@ -54,7 +54,7 @@ Result<std::shared_ptr<DataType>> JsonExtensionType::Make(
return Status::Invalid("Invalid storage type for JsonExtensionType: ",
storage_type->ToString());
}
return std::make_shared<JsonExtensionType>(storage_type);
return std::make_shared<JsonExtensionType>(std::move(storage_type));
}

std::shared_ptr<DataType> json(std::shared_ptr<DataType> storage_type) {
Expand Down

0 comments on commit 99d8ca7

Please sign in to comment.