]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Source/MigrationTools/org/tianocore/migration/Macro.java
re
[mirror_edk2.git] / Tools / Source / MigrationTools / org / tianocore / migration / Macro.java
index 47c507baf41f4b46b65a47fe71eaa963044e9af1..bd10b5a251b80129730d89c06d4bef2966f422f0 100644 (file)
@@ -15,32 +15,33 @@ package org.tianocore.migration;
 import java.util.regex.*;\r
 \r
 public class Macro {\r
-       Macro(String r8, String r9) {\r
-               r8name = r8;\r
-               r9name = r9;\r
-       }\r
-       Macro(String[] linecontext) {\r
-               r8name = linecontext[0];\r
-               r9name = linecontext[1];\r
-       }\r
-       \r
-       public String r8name;\r
-       public String r9name;\r
+    Macro(String r8, String r9) {\r
+        r8name = r8;\r
+        r9name = r9;\r
+    }\r
+    Macro(String[] linecontext) {\r
+        r8name = linecontext[0];\r
+        r9name = linecontext[1];\r
+    }\r
+    \r
+    public String r8name;\r
+    public String r9name;\r
 \r
-       public static Pattern ptntmacro = Pattern.compile("\\b[A-Z_]+\\s*?\\(?\\b",Pattern.MULTILINE);\r
+    public static Pattern ptntmacro = Pattern.compile("\\b[A-Z_]+\\s*?\\(?\\b",Pattern.MULTILINE);\r
 \r
-       private static String unmacro = "VOID UINTN BOOLEAN ASSERT OPTIONAL STATIC NULL TRUE IN OUT FALSE";\r
+    private static String unmacro = "VOID UINTN BOOLEAN ASSERT OPTIONAL STATIC NULL TRUE IN OUT FALSE";\r
 \r
-       public static String register(Matcher mtr, ModuleInfo mi, Database db) {\r
-               String temp = null;\r
-               \r
-               temp = mtr.group();\r
-               if (MigrationTool.db.hasMacro(temp)) {                                  // only changed macros registered, because the database of macro has only changed ones\r
-                       if (!unmacro.contains(temp)) {\r
-                               mi.hashnonlocalmacro.add(temp);\r
-                       }\r
-                       return temp;\r
-               }\r
-               return null;\r
-       }\r
+    public static String register(Matcher mtr, ModuleInfo mi, Database db) {\r
+        String temp = null;\r
+        \r
+        temp = mtr.group();\r
+        mi.hashmacro.add(temp);\r
+        if (MigrationTool.db.hasMacro(temp)) {                    // only changed macros registered, because the database of macro has only changed ones\r
+            if (!unmacro.contains(temp)) {\r
+                mi.hashnonlocalmacro.add(temp);\r
+            }\r
+            return temp;\r
+        }\r
+        return null;\r
+    }\r
 }
\ No newline at end of file