Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Side by Side Diff: webrtc/base/flags.h

Issue 1917043005: #include "webrtc/base/constructormagic.h" where appropriate (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « webrtc/base/fileutils.h ('k') | webrtc/base/latebindingsymboltable.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2006 The WebRTC Project Authors. All rights reserved. 2 * Copyright 2006 The WebRTC Project Authors. All rights reserved.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license 4 * Use of this source code is governed by a BSD-style license
5 * that can be found in the LICENSE file in the root of the source 5 * that can be found in the LICENSE file in the root of the source
6 * tree. An additional intellectual property rights grant can be found 6 * tree. An additional intellectual property rights grant can be found
7 * in the file PATENTS. All contributing project authors may 7 * in the file PATENTS. All contributing project authors may
8 * be found in the AUTHORS file in the root of the source tree. 8 * be found in the AUTHORS file in the root of the source tree.
9 */ 9 */
10 10
11 11
12 // Originally comes from shared/commandlineflags/flags.h 12 // Originally comes from shared/commandlineflags/flags.h
13 13
14 // Flags are defined and declared using DEFINE_xxx and DECLARE_xxx macros, 14 // Flags are defined and declared using DEFINE_xxx and DECLARE_xxx macros,
15 // where xxx is the flag type. Flags are referred to via FLAG_yyy, 15 // where xxx is the flag type. Flags are referred to via FLAG_yyy,
16 // where yyy is the flag name. For intialization and iteration of flags, 16 // where yyy is the flag name. For intialization and iteration of flags,
17 // see the FlagList class. For full programmatic access to any 17 // see the FlagList class. For full programmatic access to any
18 // flag, see the Flag class. 18 // flag, see the Flag class.
19 // 19 //
20 // The implementation only relies and basic C++ functionality 20 // The implementation only relies and basic C++ functionality
21 // and needs no special library or STL support. 21 // and needs no special library or STL support.
22 22
23 #ifndef WEBRTC_BASE_FLAGS_H__ 23 #ifndef WEBRTC_BASE_FLAGS_H__
24 #define WEBRTC_BASE_FLAGS_H__ 24 #define WEBRTC_BASE_FLAGS_H__
25 25
26 #include <assert.h> 26 #include <assert.h>
27 27
28 #include "webrtc/base/checks.h" 28 #include "webrtc/base/checks.h"
29 #include "webrtc/base/common.h" 29 #include "webrtc/base/common.h"
30 #include "webrtc/base/constructormagic.h"
30 31
31 namespace rtc { 32 namespace rtc {
32 33
33 // Internal use only. 34 // Internal use only.
34 union FlagValue { 35 union FlagValue {
35 // Note: Because in C++ non-bool values are silently converted into 36 // Note: Because in C++ non-bool values are silently converted into
36 // bool values ('bool b = "false";' results in b == true!), we pass 37 // bool values ('bool b = "false";' results in b == true!), we pass
37 // and int argument to New_BOOL as this appears to be safer - sigh. 38 // and int argument to New_BOOL as this appears to be safer - sigh.
38 // In particular, it prevents the (not uncommon!) bug where a bool 39 // In particular, it prevents the (not uncommon!) bug where a bool
39 // flag is defined via: DEFINE_bool(flag, "false", "some comment");. 40 // flag is defined via: DEFINE_bool(flag, "false", "some comment");.
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
261 char **argv_; 262 char **argv_;
262 263
263 private: 264 private:
264 RTC_DISALLOW_COPY_AND_ASSIGN(WindowsCommandLineArguments); 265 RTC_DISALLOW_COPY_AND_ASSIGN(WindowsCommandLineArguments);
265 }; 266 };
266 #endif // WEBRTC_WIN 267 #endif // WEBRTC_WIN
267 268
268 } // namespace rtc 269 } // namespace rtc
269 270
270 #endif // SHARED_COMMANDLINEFLAGS_FLAGS_H__ 271 #endif // SHARED_COMMANDLINEFLAGS_FLAGS_H__
OLDNEW
« no previous file with comments | « webrtc/base/fileutils.h ('k') | webrtc/base/latebindingsymboltable.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698