]> git.proxmox.com Git - mirror_edk2.git/blobdiff - Tools/Source/MigrationTools/org/tianocore/migration/Func.java
\t 2 \ \ \ \
[mirror_edk2.git] / Tools / Source / MigrationTools / org / tianocore / migration / Func.java
index c311f10b605186ce759ff0e94850d46c3e811f66..f00eac4e2aed9c89f34f7fb71d9b3e8bdb5fe2aa 100644 (file)
@@ -15,50 +15,50 @@ package org.tianocore.migration;
 import java.util.regex.*;\r
 \r
 public class Func {\r
-       Func(String r8func,String r8lib,String r9func,String r9lib) {\r
-               r8funcname = r8func;\r
-               r8libname = r8lib;\r
-               r9funcname = r9func;\r
-               r9libname = r9lib;\r
-       }\r
-       Func(String[] linecontext) {\r
-               r8funcname = linecontext[1];\r
-               r8libname = linecontext[0];\r
-               r9funcname = linecontext[2];\r
-               r9libname = linecontext[3];\r
-       }\r
-       public String r8funcname;\r
-       public String r8libname;\r
-       public String r9funcname;\r
-       public String r9libname;\r
+    Func(String r8func,String r8lib,String r9func,String r9lib) {\r
+        r8funcname = r8func;\r
+        r8libname = r8lib;\r
+        r9funcname = r9func;\r
+        r9libname = r9lib;\r
+    }\r
+    Func(String[] linecontext) {\r
+        r8funcname = linecontext[1];\r
+        r8libname = linecontext[0];\r
+        r9funcname = linecontext[2];\r
+        r9libname = linecontext[3];\r
+    }\r
+    public String r8funcname;\r
+    public String r8libname;\r
+    public String r9funcname;\r
+    public String r9libname;\r
 \r
-       public static Pattern ptnbrace = Pattern.compile("\\{[^\\{\\}]*\\}",Pattern.MULTILINE);\r
-       //public static Pattern ptnfuncc = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\([^\\)\\(]*\\)",Pattern.MULTILINE);\r
-       public static Pattern ptnfuncc = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\(",Pattern.MULTILINE);\r
-       public static Pattern ptnfuncd = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\([^\\)\\(]*\\)\\s*@",Pattern.MULTILINE);\r
-       public static Pattern ptnlowcase = Pattern.compile("[a-z]");                            // must be removed\r
-       \r
-       private static String reservedwords = "if for pack while switch return sizeof";\r
-       \r
-       public static String register(Matcher mtr, ModuleInfo mi, Database db) {\r
-               String temp = null;\r
+    public static Pattern ptnbrace = Pattern.compile("\\{[^\\{\\}]*\\}",Pattern.MULTILINE);\r
+    //public static Pattern ptnfuncc = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\([^\\)\\(]*\\)",Pattern.MULTILINE);\r
+    public static Pattern ptnfuncc = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\(",Pattern.MULTILINE);\r
+    public static Pattern ptnfuncd = Pattern.compile("([a-zA-Z_]\\w*)\\s*\\([^\\)\\(]*\\)\\s*@",Pattern.MULTILINE);\r
+    public static Pattern ptnlowcase = Pattern.compile("[a-z]");                // must be removed\r
+    \r
+    private static String reservedwords = "if for pack while switch return sizeof";\r
+    \r
+    public static String register(Matcher mtr, ModuleInfo mi, Database db) {\r
+        String temp = null;\r
 \r
-               temp = mtr.group(1);                                                                    // both changed and not changed funcc are registered , for finding all the non-local function calls\r
-               Matcher mtrlowcase = ptnlowcase.matcher(temp);                  // must be removed , so the two funcs can be merged\r
-               if (!reservedwords.contains(temp) && mtrlowcase.find()) {\r
-                       mi.hashfuncc.add(temp);\r
-               }\r
-               return temp;\r
-       }\r
-       /*\r
-       public static String registerFuncD(Matcher mtr, ModuleInfo mi, Database db) {\r
-               String temp = null;\r
+        temp = mtr.group(1);                                    // both changed and not changed funcc are registered , for finding all the non-local function calls\r
+        Matcher mtrlowcase = ptnlowcase.matcher(temp);            // must be removed , so the two funcs can be merged\r
+        if (!reservedwords.contains(temp) && mtrlowcase.find()) {\r
+            mi.hashfuncc.add(temp);\r
+        }\r
+        return temp;\r
+    }\r
+    /*\r
+    public static String registerFuncD(Matcher mtr, ModuleInfo mi, Database db) {\r
+        String temp = null;\r
 \r
-               temp = mtr.group(1);                                                                    // both changed and not changed funcd are registered , for finding all the non-local function calls\r
-               if (!reservedwords.contains(temp)) {\r
-                       mi.hashfuncd.add(temp);\r
-               }\r
-               return temp;\r
-       }\r
-       */\r
+        temp = mtr.group(1);                                    // both changed and not changed funcd are registered , for finding all the non-local function calls\r
+        if (!reservedwords.contains(temp)) {\r
+            mi.hashfuncd.add(temp);\r
+        }\r
+        return temp;\r
+    }\r
+    */\r
 }\r