]> git.proxmox.com Git - mirror_edk2.git/blobdiff - BaseTools/Source/Python/Common/TargetTxtClassObject.py
BaseTools: skip updating temporary variable.
[mirror_edk2.git] / BaseTools / Source / Python / Common / TargetTxtClassObject.py
index 387e5152309743b36c38b859e00f08c022b4eaa1..f8459c892e365845e2cd0d32706b27cfa84a276f 100644 (file)
@@ -45,7 +45,7 @@ class TargetTxtClassObject(object):
             DataType.TAB_TAT_DEFINES_BUILD_RULE_CONF                            : '',\r
         }\r
         self.ConfDirectoryPath = ""\r
-        if Filename != None:\r
+        if Filename is not None:\r
             self.LoadTargetTxtFile(Filename)\r
 \r
     ## LoadTargetTxtFile\r
@@ -83,7 +83,7 @@ class TargetTxtClassObject(object):
             self.ConfDirectoryPath = os.path.dirname(FileName)\r
         except:\r
             EdkLogger.error("build", FILE_OPEN_FAILURE, ExtraData=FileName)\r
-            if F != None:\r
+            if F is not None:\r
                 F.close()\r
 \r
         for Line in F:\r
@@ -137,33 +137,6 @@ class TargetTxtClassObject(object):
         F.close()\r
         return 0\r
 \r
-    ## Print the dictionary\r
-    #\r
-    # Print all items of dictionary one by one\r
-    #\r
-    # @param Dict:  The dictionary to be printed\r
-    #\r
-    def printDict(Dict):\r
-        if Dict != None:\r
-            KeyList = Dict.keys()\r
-            for Key in KeyList:\r
-                if Dict[Key] != '':\r
-                    print Key + ' = ' + str(Dict[Key])\r
-\r
-    ## Print the dictionary\r
-    #\r
-    # Print the items of dictionary which matched with input key\r
-    #\r
-    # @param list:  The dictionary to be printed\r
-    # @param key:   The key of the item to be printed\r
-    #\r
-    def printList(Key, List):\r
-        if type(List) == type([]):\r
-            if len(List) > 0:\r
-                if Key.find(TAB_SPLIT) != -1:\r
-                    print "\n" + Key\r
-                    for Item in List:\r
-                        print Item\r
 ## TargetTxtDict\r
 #\r
 # Load target.txt in input Conf dir\r