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

Side by Side Diff: tools/clang/plugins/ChromeClassTester.cpp

Issue 14064011: Add url/ to banned_directories in clang style checker. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add TODO Created 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 // A general interface for filtering and only acting on classes in Chromium C++ 5 // A general interface for filtering and only acting on classes in Chromium C++
6 // code. 6 // code.
7 7
8 #include "ChromeClassTester.h" 8 #include "ChromeClassTester.h"
9 9
10 #include <sys/param.h> 10 #include <sys/param.h>
(...skipping 123 matching lines...) Expand 10 before | Expand all | Expand 10 after
134 134
135 return false; 135 return false;
136 } 136 }
137 137
138 void ChromeClassTester::BuildBannedLists() { 138 void ChromeClassTester::BuildBannedLists() {
139 banned_namespaces_.push_back("std"); 139 banned_namespaces_.push_back("std");
140 banned_namespaces_.push_back("__gnu_cxx"); 140 banned_namespaces_.push_back("__gnu_cxx");
141 banned_namespaces_.push_back("WebKit"); 141 banned_namespaces_.push_back("WebKit");
142 banned_namespaces_.push_back("WebTestRunner"); 142 banned_namespaces_.push_back("WebTestRunner");
143 143
144 banned_directories_.push_back("third_party/");
145 banned_directories_.push_back("native_client/");
146 banned_directories_.push_back("breakpad/"); 144 banned_directories_.push_back("breakpad/");
147 banned_directories_.push_back("courgette/"); 145 banned_directories_.push_back("courgette/");
146 banned_directories_.push_back("dart/");
147 banned_directories_.push_back("frameworks/");
148 banned_directories_.push_back("googleurl/");
149 banned_directories_.push_back("icu4c/");
150 banned_directories_.push_back("native_client/");
148 banned_directories_.push_back("pdf/"); 151 banned_directories_.push_back("pdf/");
149 banned_directories_.push_back("ppapi/"); 152 banned_directories_.push_back("ppapi/");
153 banned_directories_.push_back("sdch/");
154 banned_directories_.push_back("testing/");
155 banned_directories_.push_back("third_party/");
156 // TODO(tfarina): Remove this when ready. crbug.com/229660
157 banned_directories_.push_back("url/");
Nico 2013/04/16 01:51:50 Do you want to put this behind a flag so that you
150 banned_directories_.push_back("usr/"); 158 banned_directories_.push_back("usr/");
151 banned_directories_.push_back("testing/");
152 banned_directories_.push_back("googleurl/");
153 banned_directories_.push_back("v8/"); 159 banned_directories_.push_back("v8/");
154 banned_directories_.push_back("dart/");
155 banned_directories_.push_back("sdch/");
156 banned_directories_.push_back("icu4c/");
157 banned_directories_.push_back("frameworks/");
158 160
159 // Don't check autogenerated headers. 161 // Don't check autogenerated headers.
160 // Make puts them below $(builddir_name)/.../gen and geni. 162 // Make puts them below $(builddir_name)/.../gen and geni.
161 // Ninja puts them below OUTPUT_DIR/.../gen 163 // Ninja puts them below OUTPUT_DIR/.../gen
162 // Xcode has a fixed output directory for everything. 164 // Xcode has a fixed output directory for everything.
163 banned_directories_.push_back("gen/"); 165 banned_directories_.push_back("gen/");
164 banned_directories_.push_back("geni/"); 166 banned_directories_.push_back("geni/");
165 banned_directories_.push_back("xcodebuild/"); 167 banned_directories_.push_back("xcodebuild/");
166 168
167 // You are standing in a mazy of twisty dependencies, all resolved by 169 // You are standing in a mazy of twisty dependencies, all resolved by
(...skipping 122 matching lines...) Expand 10 before | Expand all | Expand 10 after
290 PresumedLoc ploc = source_manager.getPresumedLoc(spelling_location); 292 PresumedLoc ploc = source_manager.getPresumedLoc(spelling_location);
291 if (ploc.isInvalid()) { 293 if (ploc.isInvalid()) {
292 // If we're in an invalid location, we're looking at things that aren't 294 // If we're in an invalid location, we're looking at things that aren't
293 // actually stated in the source. 295 // actually stated in the source.
294 return false; 296 return false;
295 } 297 }
296 298
297 *filename = ploc.getFilename(); 299 *filename = ploc.getFilename();
298 return true; 300 return true;
299 } 301 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698