Commit c0ec16e5 authored by thechargingvolcano's avatar thechargingvolcano Committed by Commit bot

[tools] gen-postmortem-metadata: use strip instead of lstrip + rstrip

In Python, `strip` can be used directly instead of stripping the ends
one by one.

R=machenbach@chromium.org
NOTRY=true

Review URL: https://codereview.chromium.org/1443963004

Cr-Commit-Position: refs/heads/master@{#32413}
parent 252bb3a8
......@@ -319,7 +319,7 @@ def load_objects():
in_insttype = False;
continue;
line = re.sub('//.*', '', line.rstrip().lstrip());
line = re.sub('//.*', '', line.strip());
if (in_insttype):
typestr += line;
......@@ -329,10 +329,10 @@ def load_objects():
line);
if (match):
klass = match.group(1).rstrip().lstrip();
klass = match.group(1).strip();
pklass = match.group(3);
if (pklass):
pklass = pklass.rstrip().lstrip();
pklass = pklass.strip();
klasses[klass] = { 'parent': pklass };
#
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment