blob: 742a4cc7b41cd5a3ff11e2eb10c978956e227287 [file] [log] [blame]
// Copyright 2023 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "gn/resolved_target_data.h"
ResolvedTargetData::TargetInfo* ResolvedTargetData::GetTargetInfo(
const Target* target) const {
auto ret = targets_.PushBackWithIndex(target);
if (ret.first) {
infos_.push_back(std::make_unique<TargetInfo>(target));
}
return infos_[ret.second].get();
}