summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--chrome/common/DEPS3
-rwxr-xr-xtools/checkdeps/checkdeps.py15
2 files changed, 14 insertions, 4 deletions
diff --git a/chrome/common/DEPS b/chrome/common/DEPS
index 044e2f8..ed2c80a 100644
--- a/chrome/common/DEPS
+++ b/chrome/common/DEPS
@@ -17,7 +17,4 @@ include_rules = [
# FIXME - refactor code and remove these dependencies
"+chrome/app",
"+chrome/browser",
-
- # See bug 7828
- "+chrome/renderer",
]
diff --git a/tools/checkdeps/checkdeps.py b/tools/checkdeps/checkdeps.py
index 9cbfa2f..96e9a16 100755
--- a/tools/checkdeps/checkdeps.py
+++ b/tools/checkdeps/checkdeps.py
@@ -330,8 +330,21 @@ def CheckFile(rules, file_name):
ret_val = "" # We'll collect the error messages in here
try:
cur_file = open(file_name, "r")
+ in_if0 = 0
for cur_line in range(MAX_LINES):
- cur_line = cur_file.readline(MAX_LINE_LENGTH)
+ cur_line = cur_file.readline(MAX_LINE_LENGTH).strip()
+
+ # Check to see if we're at / inside a #if 0 block
+ if cur_line == '#if 0':
+ in_if0 += 1
+ continue
+ if in_if0 > 0:
+ if cur_line.startswith('#if'):
+ in_if0 += 1
+ elif cur_line == '#endif':
+ in_if0 -= 1
+ continue
+
line_status = CheckLine(rules, cur_line)
if line_status is not None:
if len(line_status) > 0: # Add newline to separate messages.