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

Unified Diff: build/mac/generate_localizer

Issue 165133: Bounce through a set so we uniq the string list to avoid having something lis... (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 11 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/mac/generate_localizer
===================================================================
--- build/mac/generate_localizer (revision 22731)
+++ build/mac/generate_localizer (working copy)
@@ -97,8 +97,9 @@
def generate_files_contents(class_name, constants_list, header_name, xib_path):
"""Generates a localizer files contents from the list of constants."""
- # Copy and sort the list, then build the strings we need from it.
- constants_list = constants_list[:]
+ # Bounce through a set to uniq the strings, sort the list, then build the
+ # values we need from it.
+ constants_list = list(set(constants_list))
constants_list.sort()
Mark Mentovai 2009/08/07 16:38:48 Even better: constants_list = sorted(set(constant
constant_list_str = ''
for item in constants_list:
« 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