Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #ifndef BASE_LOGGING_H_ | 5 #ifndef BASE_LOGGING_H_ |
| 6 #define BASE_LOGGING_H_ | 6 #define BASE_LOGGING_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 | 9 |
| 10 #include <cassert> | 10 #include <cassert> |
| 11 #include <cstring> | 11 #include <cstring> |
| 12 #include <sstream> | 12 #include <sstream> |
| 13 #include <string> | 13 #include <string> |
| 14 #include <type_traits> | 14 #include <type_traits> |
| 15 #include <utility> | 15 #include <utility> |
| 16 | 16 |
| 17 #include "base/base_export.h" | 17 #include "base/base_export.h" |
| 18 #include "base/debug/debugger.h" | 18 #include "base/debug/debugger.h" |
| 19 #include "base/macros.h" | 19 #include "base/macros.h" |
| 20 #include "base/template_util.h" | 20 #include "base/template_util.h" |
| 21 #include "build/build_config.h" | 21 #include "build/build_config.h" |
| 22 | 22 |
| 23 #if defined(OS_WIN) | |
|
danakj
2016/12/09 04:52:05
This shouldn't be here its not used right
| |
| 24 #include <windows.h> | |
| 25 #endif | |
| 26 | |
| 23 // | 27 // |
| 24 // Optional message capabilities | 28 // Optional message capabilities |
| 25 // ----------------------------- | 29 // ----------------------------- |
| 26 // Assertion failed messages and fatal errors are displayed in a dialog box | 30 // Assertion failed messages and fatal errors are displayed in a dialog box |
| 27 // before the application exits. However, running this UI creates a message | 31 // before the application exits. However, running this UI creates a message |
| 28 // loop, which causes application messages to be processed and potentially | 32 // loop, which causes application messages to be processed and potentially |
| 29 // dispatched to existing application windows. Since the application is in a | 33 // dispatched to existing application windows. Since the application is in a |
| 30 // bad state when this assertion dialog is displayed, these messages may not | 34 // bad state when this assertion dialog is displayed, these messages may not |
| 31 // get processed and hang the dialog, or the application might go crazy. | 35 // get processed and hang the dialog, or the application might go crazy. |
| 32 // | 36 // |
| (...skipping 982 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1015 #elif NOTIMPLEMENTED_POLICY == 5 | 1019 #elif NOTIMPLEMENTED_POLICY == 5 |
| 1016 #define NOTIMPLEMENTED() do {\ | 1020 #define NOTIMPLEMENTED() do {\ |
| 1017 static bool logged_once = false;\ | 1021 static bool logged_once = false;\ |
| 1018 LOG_IF(ERROR, !logged_once) << NOTIMPLEMENTED_MSG;\ | 1022 LOG_IF(ERROR, !logged_once) << NOTIMPLEMENTED_MSG;\ |
| 1019 logged_once = true;\ | 1023 logged_once = true;\ |
| 1020 } while(0);\ | 1024 } while(0);\ |
| 1021 EAT_STREAM_PARAMETERS | 1025 EAT_STREAM_PARAMETERS |
| 1022 #endif | 1026 #endif |
| 1023 | 1027 |
| 1024 #endif // BASE_LOGGING_H_ | 1028 #endif // BASE_LOGGING_H_ |
| OLD | NEW |