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

Side by Side Diff: build/config/compiler/BUILD.gn

Issue 1892143004: Remove disabling of C4267 in 64-bit gn builds (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix long line Created 4 years, 8 months 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
« no previous file with comments | « no previous file | components/gcm_driver/crypto/gcm_message_cryptographer.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 import("//build/config/android/config.gni") 5 import("//build/config/android/config.gni")
6 import("//build/config/chrome_build.gni") 6 import("//build/config/chrome_build.gni")
7 import("//build/config/compiler/compiler.gni") 7 import("//build/config/compiler/compiler.gni")
8 import("//build/config/nacl/config.gni") 8 import("//build/config/nacl/config.gni")
9 import("//build/toolchain/cc_wrapper.gni") 9 import("//build/toolchain/cc_wrapper.gni")
10 import("//build/toolchain/toolchain.gni") 10 import("//build/toolchain/toolchain.gni")
(...skipping 817 matching lines...) Expand 10 before | Expand all | Expand 10 after
828 # should work through these at some point -- they may be removed from 828 # should work through these at some point -- they may be removed from
829 # the RTM release in the /W4 set. 829 # the RTM release in the /W4 set.
830 "/wd4456", 830 "/wd4456",
831 "/wd4457", 831 "/wd4457",
832 "/wd4458", 832 "/wd4458",
833 "/wd4459", 833 "/wd4459",
834 ] 834 ]
835 835
836 if (visual_studio_version == "2015") { 836 if (visual_studio_version == "2015") {
837 cflags += [ 837 cflags += [
838 # VC++ 2015 changes 32-bit size_t truncation warnings from 4244 to 4267.
839 # Example: short TruncTest(size_t x) { return x; }
840 # Since we disable 4244 we need to disable 4267 during migration.
841 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
842 "/wd4267",
843
844 # C4312 is a VS 2015 64-bit warning for integer to larger pointer. 838 # C4312 is a VS 2015 64-bit warning for integer to larger pointer.
845 # TODO(brucedawson): fix warnings, crbug.com/554200 839 # TODO(brucedawson): fix warnings, crbug.com/554200
846 "/wd4312", 840 "/wd4312",
847 841
848 # TODO(brucedawson): http://crbug.com/593448 - C4595 is an 'illegal 842 # TODO(brucedawson): http://crbug.com/593448 - C4595 is an 'illegal
849 # inline operator new' warning that is new in VS 2015 Update 2. 843 # inline operator new' warning that is new in VS 2015 Update 2.
850 # This is equivalent to clang's no-inline-new-delete warning. 844 # This is equivalent to clang's no-inline-new-delete warning.
851 # See http://bugs.icu-project.org/trac/ticket/11122 845 # See http://bugs.icu-project.org/trac/ticket/11122
852 "/wd4595", 846 "/wd4595",
853 ] 847 ]
848
849 if (current_cpu == "x86") {
850 cflags += [
851 # VC++ 2015 changes 32-bit size_t truncation warnings from 4244 to
852 # 4267. Example: short TruncTest(size_t x) { return x; }
853 # Since we disable 4244 we need to disable 4267 during migration.
854 # TODO(jschuh): crbug.com/167187 fix size_t to int truncations.
855 "/wd4267",
856 ]
857 }
854 } 858 }
855 859
856 # VS xtree header file needs to be patched or 4702 (unreachable code 860 # VS xtree header file needs to be patched or 4702 (unreachable code
857 # warning) is reported if _HAS_EXCEPTIONS=0. Disable the warning if xtree is 861 # warning) is reported if _HAS_EXCEPTIONS=0. Disable the warning if xtree is
858 # not patched. 862 # not patched.
859 if (!msvs_xtree_patched && 863 if (!msvs_xtree_patched &&
860 exec_script("../../win_is_xtree_patched.py", [], "value") == 0) { 864 exec_script("../../win_is_xtree_patched.py", [], "value") == 0) {
861 cflags += [ "/wd4702" ] # Unreachable code. 865 cflags += [ "/wd4702" ] # Unreachable code.
862 } 866 }
863 867
(...skipping 536 matching lines...) Expand 10 before | Expand all | Expand 10 after
1400 1404
1401 if (is_ios || is_mac) { 1405 if (is_ios || is_mac) {
1402 # On Mac and iOS, this enables support for ARC (automatic ref-counting). 1406 # On Mac and iOS, this enables support for ARC (automatic ref-counting).
1403 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html. 1407 # See http://clang.llvm.org/docs/AutomaticReferenceCounting.html.
1404 config("enable_arc") { 1408 config("enable_arc") {
1405 common_flags = [ "-fobjc-arc" ] 1409 common_flags = [ "-fobjc-arc" ]
1406 cflags_objc = common_flags 1410 cflags_objc = common_flags
1407 cflags_objcc = common_flags 1411 cflags_objcc = common_flags
1408 } 1412 }
1409 } 1413 }
OLDNEW
« no previous file with comments | « no previous file | components/gcm_driver/crypto/gcm_message_cryptographer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698