Resolve clang-tidy warnings 'readability-redundant-smartptr-get'

4 instances of the following issue: redundant get() call on smart pointer

Tested: Only through CI. There are no changes in behavior, all possible problems would be found through a compilation failure.
Change-Id: Ib11432baef83d3daebd800b365183e1ea6621136
Reviewed-on: https://dart-review.googlesource.com/c/sdk/+/240540
Reviewed-by: Aske Simon Christensen <askesc@google.com>
Commit-Queue: Oleh Prypin <oprypin@google.com>
This commit is contained in:
Oleh Prypin 2022-04-11 15:42:01 +00:00 committed by Commit Bot
parent 3d27f5cb79
commit a3478da7fa
4 changed files with 5 additions and 5 deletions

View file

@ -224,7 +224,7 @@ static bool OnIsolateInitialize(void** child_callback_data, char** error) {
result = DartUtils::ResolveScript(Dart_NewStringFromCString(script_uri));
if (Dart_IsError(result)) goto failed;
if (isolate_group_data->kernel_buffer().get() != nullptr) {
if (isolate_group_data->kernel_buffer() != nullptr) {
// Various core-library parts will send requests to the Loader to resolve
// relative URIs and perform other related tasks. We need Loader to be
// initialized for this to work because loading from Kernel binary

View file

@ -583,8 +583,8 @@ void SSLFilter::MarkAsTrusted(Dart_NativeArguments args) {
DartUtils::GetNativeBooleanArgument(args, 2)));
if (SSL_LOG_STATUS) {
Syslog::Print("Mark %p as %strusted certificate\n",
certificate_trust_state_.get()->x509(),
certificate_trust_state_.get()->is_trusted() ? "" : "not ");
certificate_trust_state_->x509(),
certificate_trust_state_->is_trusted() ? "" : "not ");
}
}

View file

@ -2647,7 +2647,7 @@ void Isolate::Shutdown() {
// Post message before LowLevelShutdown that sends onExit message.
// This ensures that exit message comes last.
if (bequest_.get() != nullptr) {
if (bequest_ != nullptr) {
auto beneficiary = bequest_->beneficiary();
auto handle = bequest_->TakeHandle();
PortMap::PostMessage(

View file

@ -588,7 +588,7 @@ bool IsolateGroupReloadContext::Reload(bool force_reload,
NoActiveIsolateScope no_active_isolate_scope;
ExternalTypedData& external_typed_data =
ExternalTypedData::Handle(Z, kernel_program.get()->typed_data()->ptr());
ExternalTypedData::Handle(Z, kernel_program->typed_data()->ptr());
IsolateGroupSource* source = IsolateGroup::Current()->source();
source->add_loaded_blob(Z, external_typed_data);