Skip to content

Commit cad4064

Browse files
Fix the compile error of ParseCommandLineFlags with Abseil LTS 20230802.
* Added the check of the Abseil version to the arguments of ParseCommandLineImpl. * #790 #codehealth PiperOrigin-RevId: 561867167
1 parent 8102aa0 commit cad4064

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

src/base/init_mozc.cc

+3
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,10 @@ std::string GetLogFilePathFromProgramName(const std::string &program_name) {
8787
void ParseCommandLineFlags(int argc, char **argv) {
8888
absl::flags_internal::ParseCommandLineImpl(
8989
argc, argv,
90+
#if defined(ABSL_LTS_RELEASE_VERSION) && ABSL_LTS_RELEASE_VERSION < 20230802
91+
// Abseil LTS 20230802 or later no longer use ArgvlistAction.
9092
absl::flags_internal::ArgvListAction::kRemoveParsedArgs,
93+
#endif // ABSL_LTS_RELEASE_VERSION < 20230802
9194
// Suppress help messages invoked by --help and others.
9295
// Use UsageFlagsAction::kHandleUsage to enable it.
9396
absl::flags_internal::UsageFlagsAction::kIgnoreUsage,

0 commit comments

Comments
 (0)