Lines Matching refs:flag
52 void RegisterFlag(CommandLineFlag& flag);
104 void FlagRegistry::RegisterFlag(CommandLineFlag& flag) { in RegisterFlag() argument
107 flags_.insert(FlagMap::value_type(flag.Name(), &flag)); in RegisterFlag()
110 if (flag.IsRetired() != old_flag.IsRetired()) { in RegisterFlag()
114 "Retired flag '", flag.Name(), "' was defined normally in file '", in RegisterFlag()
115 (flag.IsRetired() ? old_flag.Filename() : flag.Filename()), "'."), in RegisterFlag()
117 } else if (flags_internal::PrivateHandleAccessor::TypeId(flag) != in RegisterFlag()
120 absl::StrCat("Flag '", flag.Name(), in RegisterFlag()
123 old_flag.Filename(), "' and '", flag.Filename(), "'."), in RegisterFlag()
127 } else if (old_flag.Filename() != flag.Filename()) { in RegisterFlag()
129 absl::StrCat("Flag '", flag.Name(), in RegisterFlag()
131 old_flag.Filename(), "' and '", flag.Filename(), "')."), in RegisterFlag()
136 "Something is wrong with flag '", flag.Name(), "' in file '", in RegisterFlag()
137 flag.Filename(), "'. One possibility: file '", flag.Filename(), in RegisterFlag()
171 bool RegisterCommandLineFlag(CommandLineFlag& flag) { in RegisterCommandLineFlag() argument
172 FlagRegistry::GlobalRegistry().RegisterFlag(flag); in RegisterCommandLineFlag()
245 auto* flag = ::new (static_cast<void*>(buf)) in Retire() local
247 FlagRegistry::GlobalRegistry().RegisterFlag(*flag); in Retire()
262 flags_internal::ForEachFlag([&](CommandLineFlag& flag) { in SaveFromRegistry() argument
264 flags_internal::PrivateHandleAccessor::SaveState(flag)) { in SaveFromRegistry()
310 flags_internal::ForEachFlag([&](CommandLineFlag& flag) { in GetAllFlags() argument
311 res.insert({flag.Name(), &flag}); in GetAllFlags()