Provide an inline implementation of IsEnabled.

This is temporary to avoid breaking downstream builds.

BUG=none
TBR=sprang@webrtc.org
NOTRY=true

Review-Url: https://codereview.webrtc.org/2719233003
Cr-Commit-Position: refs/heads/master@{#16918}
This commit is contained in:
tommi 2017-02-28 09:26:22 -08:00 committed by Commit bot
parent 907abd8414
commit 9751c45910
2 changed files with 4 additions and 5 deletions

View File

@ -64,7 +64,10 @@ std::string FindFullName(const std::string& name);
// Convenience method, returns true iff FindFullName(name) return a string that
// starts with "Enabled".
bool IsEnabled(const char* name);
// TODO(tommi): Make sure all implementations support this.
inline bool IsEnabled(const char* name) {
return FindFullName(name).find("Enabled") == 0;
}
} // namespace field_trial
} // namespace webrtc

View File

@ -53,10 +53,6 @@ std::string FindFullName(const std::string& name) {
return std::string();
}
bool IsEnabled(const char* name) {
return FindFullName(name).find("Enabled") == 0;
}
// Optionally initialize field trial from a string.
void InitFieldTrialsFromString(const char* trials_string) {
trials_init_string = trials_string;