aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Bishop <mbtyke@gmail.com>2013-05-24 14:48:33 -0400
committerMichael Bishop <mbtyke@gmail.com>2013-05-24 14:48:33 -0400
commit1fa15abb03e0e2c40761a3226b60d3f8a3e96231 (patch)
treefb216cb8dcbc1b6b0c671c30e0f04490a8a827bc
parentc5fb79f031969c58bf9281e9b7b339076ca6a3c2 (diff)
Simplified code by using a tuple in combination with `endsWith`.
-rwxr-xr-xemcc5
1 files changed, 2 insertions, 3 deletions
diff --git a/emcc b/emcc
index f3461c7b..3bd8b3d9 100755
--- a/emcc
+++ b/emcc
@@ -629,9 +629,8 @@ header = False # pre-compiled headers. We fake that by just copying the file
for i in range(1, len(sys.argv)):
arg = sys.argv[i]
if not arg.startswith('-'):
- for extension in ['.c','.m']:
- if arg.endswith(extension):
- use_cxx = False
+ if arg.endswith(('.c','.m')):
+ use_cxx = False
if arg.endswith('.h') and sys.argv[i-1] != '-include':
header = True