Browse Source

[Tools] Fix the CPP file type in Keil.

Bernard Xiong 9 years ago
parent
commit
9c48f9e09c
1 changed files with 3 additions and 3 deletions
  1. 3 3
      tools/keil.py

+ 3 - 3
tools/keil.py

@@ -34,12 +34,12 @@ from utils import xml_indent
 fs_encoding = sys.getfilesystemencoding()
 
 def _get_filetype(fn):
+    if fn.rfind('.cpp') != -1 or fn.rfind('.cxx') != -1:
+        return 8
+
     if fn.rfind('.c') != -1 or fn.rfind('.C') != -1:
         return 1
 
-	if fn.rfind('.cpp') != -1 or fn.rfined('.cxx') != -1:
-		return 8
-
     # assemble file type
     if fn.rfind('.s') != -1 or fn.rfind('.S') != -1:
         return 2