[llvm] [llvm-strings] Add --encoding={s,S,u} option (PR #221794)

James Henderson via llvm-commits llvm-commits at lists.llvm.org
Wed Sep 9 01:14:40 PDT 2026


================
@@ -71,7 +75,10 @@ static cl::list<std::string> InputFileNames(cl::Positional,
 static int MinLength = 4;
 static bool PrintFileName;
 
-enum radix { none, octal, hexadecimal, decimal };
+enum class encoding { s, S, u };
+static encoding Encoding;
+
+enum class radix { none, octal, hexadecimal, decimal };
----------------
jh7370 wrote:

I'm not opposed to you making `radix` an `enum class`, but it doesn't belong in this PR. You can make a minor fix in a separate PR. While you're at it, you should probably rename the values to match LLVM coding standards for `enum class` values (NB: this means you don't need the prefix mentioned in the coding standards documentation, but you should follow the casing rules).

https://github.com/llvm/llvm-project/pull/221794


More information about the llvm-commits mailing list