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

Side by Side Diff: src/trusted/validator_arm/dgen_output.py

Issue 12450015: **/*.py: use /usr/bin/env to find python Base URL: https://chromium.googlesource.com/native_client/src/native_client@master
Patch Set: Created 7 years, 9 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 | « src/trusted/validator_arm/dgen_opt.py ('k') | src/trusted/validator_arm/dgen_test_output.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright (c) 2012 The Native Client Authors. All rights reserved. 3 # Copyright (c) 2012 The Native Client Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 # 6 #
7 7
8 """ 8 """
9 Some common boilerplates and helper functions for source code generation 9 Some common boilerplates and helper functions for source code generation
10 in files dgen_test_output.py and dgen_decode_output.py. 10 in files dgen_test_output.py and dgen_decode_output.py.
11 """ 11 """
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
77 """Returns true if the prefix is less than or equal to the 77 """Returns true if the prefix is less than or equal to the
78 corresponding prefix length of the decoder name.""" 78 corresponding prefix length of the decoder name."""
79 decoder_name = name_fcn(decoder) 79 decoder_name = name_fcn(decoder)
80 prefix_len = len(prefix) 80 prefix_len = len(prefix)
81 decoder_len = len(decoder_name) 81 decoder_len = len(decoder_name)
82 decoder_prefix = (decoder_name[0:prefix_len] 82 decoder_prefix = (decoder_name[0:prefix_len]
83 if prefix_len < decoder_len 83 if prefix_len < decoder_len
84 else decoder_name) 84 else decoder_name)
85 return prefix <= decoder_prefix 85 return prefix <= decoder_prefix
86 86
OLDNEW
« no previous file with comments | « src/trusted/validator_arm/dgen_opt.py ('k') | src/trusted/validator_arm/dgen_test_output.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698