Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(412)

Side by Side Diff: tools/gn/args.cc

Issue 2561963002: base: Remove the string logging from CHECK(). (Closed)
Patch Set: checkstring: rebase Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "tools/gn/args.h" 5 #include "tools/gn/args.h"
6 6
7 #include "base/sys_info.h" 7 #include "base/sys_info.h"
8 #include "build/build_config.h" 8 #include "build/build_config.h"
9 #include "tools/gn/string_utils.h" 9 #include "tools/gn/string_utils.h"
10 #include "tools/gn/variables.h" 10 #include "tools/gn/variables.h"
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after
299 arch = kArm; 299 arch = kArm;
300 else if (os_arch == "aarch64") 300 else if (os_arch == "aarch64")
301 arch = kArm64; 301 arch = kArm64;
302 else if (os_arch == "mips") 302 else if (os_arch == "mips")
303 arch = kMips; 303 arch = kMips;
304 else if (os_arch == "s390x") 304 else if (os_arch == "s390x")
305 arch = kS390X; 305 arch = kS390X;
306 else if (os_arch == "mips") 306 else if (os_arch == "mips")
307 arch = kPPC64; 307 arch = kPPC64;
308 else 308 else
309 CHECK(false) << "OS architecture not handled. (" << os_arch << ")"; 309 // OS architecture not handled. (|os_arch|)
310 CHECK(false);
310 311
311 // Save the OS and architecture as build arguments that are implicitly 312 // Save the OS and architecture as build arguments that are implicitly
312 // declared. This is so they can be overridden in a toolchain build args 313 // declared. This is so they can be overridden in a toolchain build args
313 // override, and so that they will appear in the "gn args" output. 314 // override, and so that they will appear in the "gn args" output.
314 Value empty_string(nullptr, std::string()); 315 Value empty_string(nullptr, std::string());
315 316
316 Value os_val(nullptr, std::string(os)); 317 Value os_val(nullptr, std::string(os));
317 dest->SetValue(variables::kHostOs, os_val, nullptr); 318 dest->SetValue(variables::kHostOs, os_val, nullptr);
318 dest->SetValue(variables::kTargetOs, empty_string, nullptr); 319 dest->SetValue(variables::kTargetOs, empty_string, nullptr);
319 dest->SetValue(variables::kCurrentOs, empty_string, nullptr); 320 dest->SetValue(variables::kCurrentOs, empty_string, nullptr);
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
371 Scope* scope) const { 372 Scope* scope) const {
372 lock_.AssertAcquired(); 373 lock_.AssertAcquired();
373 return declared_arguments_per_toolchain_[scope->settings()]; 374 return declared_arguments_per_toolchain_[scope->settings()];
374 } 375 }
375 376
376 Scope::KeyValueMap& Args::OverridesForToolchainLocked( 377 Scope::KeyValueMap& Args::OverridesForToolchainLocked(
377 Scope* scope) const { 378 Scope* scope) const {
378 lock_.AssertAcquired(); 379 lock_.AssertAcquired();
379 return toolchain_overrides_[scope->settings()]; 380 return toolchain_overrides_[scope->settings()];
380 } 381 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698