| /third_party/python/Lib/test/support/ |
| D | warnings_helper.py | 6 import warnings 11 with warnings.catch_warnings(): 12 warnings.simplefilter('ignore', category=DeprecationWarning) 20 with warnings.catch_warnings(record=True) as warns: 21 warnings.simplefilter('always', SyntaxWarning) 38 with warnings.catch_warnings(record=True) as warns: 39 warnings.simplefilter('error', SyntaxWarning) 42 # No warnings are leaked when a SyntaxError is raised. 47 """Decorator to suppress warnings. 49 Use of context managers to hide warnings make diffs [all …]
|
| /third_party/python/Lib/unittest/test/ |
| D | _test_warnings.py | 4 This module has a number of tests that raise different kinds of warnings. 5 When the tests are run, the warnings are caught and their messages are printed 7 unittest.main to affect the behavior of warnings. 9 combinations of warnings args and -W flags and check that the output is correct. 15 import warnings 18 warnings.warn('rw', RuntimeWarning) 21 # unittest warnings will be printed at most once per type (max one message 36 # these warnings are normally silenced, but they are printed in unittest 38 warnings.warn('dw', DeprecationWarning) 39 warnings.warn('dw', DeprecationWarning) [all …]
|
| /third_party/python/Doc/library/ |
| D | warnings.rst | 1 :mod:`warnings` --- Warning control 4 .. module:: warnings 7 **Source code:** :source:`Lib/warnings.py` 9 .. index:: single: warnings 18 Python programmers issue warnings by calling the :func:`warn` function defined 23 can be changed flexibly, from ignoring all warnings to turning them into 24 exceptions. The disposition of warnings can vary based on the :ref:`warning category 44 :func:`logging.captureWarnings` allows you to handle all warnings with 54 This categorization is useful to be able to filter out groups of warnings. 58 documented here, because conceptually they belong to the warnings mechanism. [all …]
|
| /third_party/python/Tools/scripts/ |
| D | fixdiv.py | 5 To use this tool, first run `python -Qwarnall yourscript.py 2>warnings'. 8 `warnings'. The warnings look like this: 12 The warnings are written to stderr, so you must use `2>' for the I/O 17 The warnings are not limited to the script; modules imported by the 18 script may also trigger warnings. In fact a useful technique is to 22 Then run `python fixdiv.py warnings'. This first reads the warnings, 23 looking for classic division warnings, and sorts them by file name and 25 it parses the file and tries to match the warnings up to the division 58 A / operator was found for which no warnings were seen. This could 68 - 'Phantom ... warnings for line N', line marked by '*': [all …]
|
| /third_party/rust/rust/tests/ui/parser/ |
| D | stmt_expr_attrs_placement.rs | 7 let a = #![allow(warnings)] (1, 2); in main() 10 let b = (#![allow(warnings)] 1, 2); in main() 14 #![allow(warnings)] in main() 15 (#![allow(warnings)] 1, 2) in main() 20 #![allow(warnings)] in main() 21 let e = (#![allow(warnings)] 1, 2); in main() 26 let e = [#![allow(warnings)] 1, 2]; in main() 29 let f = [#![allow(warnings)] 1; 0]; in main() 32 let g = match true { #![allow(warnings)] _ => {} }; in main() 36 let h = MyStruct { #![allow(warnings)] field: 0 }; in main()
|
| /third_party/python/Lib/idlelib/idle_test/ |
| D | test_warning.py | 1 '''Test warnings replacement in pyshell.py and run.py. 6 Make sure warnings module is left unaltered (http://bugs.python.org/issue18081). 12 import warnings 15 showwarning = warnings.showwarning 23 Warning (from warnings module): 35 self.assertIs(warnings.showwarning, showwarning) 37 self.assertIs(warnings.showwarning, run.idle_showwarning_subproc) 39 self.assertIs(warnings.showwarning, showwarning) 53 self.assertIs(warnings.showwarning, showwarning) 55 self.assertIs(warnings.showwarning, shell.idle_showwarning) [all …]
|
| /third_party/python/Lib/test/test_importlib/import_/ |
| D | test___package__.py | 8 import warnings 53 with warnings.catch_warnings(): 54 warnings.simplefilter("ignore") 65 with warnings.catch_warnings(): 66 warnings.simplefilter("ignore") 102 with warnings.catch_warnings(): 103 warnings.simplefilter("ignore", ImportWarning) 107 with warnings.catch_warnings(): 108 warnings.simplefilter("ignore", ImportWarning) 169 with warnings.catch_warnings(): [all …]
|
| D | test_api.py | 7 import warnings 105 with warnings.catch_warnings(): 106 warnings.simplefilter("ignore", ImportWarning) 110 with warnings.catch_warnings(): 111 warnings.simplefilter("ignore", ImportWarning) 115 with warnings.catch_warnings(): 116 warnings.simplefilter("ignore", ImportWarning) 120 with warnings.catch_warnings(): 121 warnings.simplefilter("ignore", ImportWarning) 125 with warnings.catch_warnings(): [all …]
|
| D | test_path.py | 11 import warnings 77 with warnings.catch_warnings(record=True) as w: 78 warnings.simplefilter('always', ImportWarning) 79 warnings.simplefilter('ignore', DeprecationWarning) 127 with warnings.catch_warnings(): 128 warnings.simplefilter("ignore", ImportWarning) 134 with warnings.catch_warnings(): 135 warnings.simplefilter("ignore", ImportWarning) 147 with warnings.catch_warnings(): 148 warnings.simplefilter("ignore", ImportWarning) [all …]
|
| /third_party/protobuf/ruby/tests/ |
| D | utf8.rb | 8 @@warnings = nil 13 if @@warnings 14 @@warnings << message 21 @@warnings = [] 23 @@warnings 25 @@warnings = nil 60 warnings = CaptureWarnings.capture(&block) 61 assert_equal 1, warnings.length 62 assert_match(/String is invalid UTF-8. This will be an error in a future version./, warnings[0]) 86 warnings = CaptureWarnings.capture(&block) [all …]
|
| /third_party/rust/rust/tests/ui/lint/ |
| D | issue-80988.stderr | 1 warning: deny(warnings) incompatible with previous forbid 4 LL | #![forbid(warnings)] 7 LL | #[deny(warnings)] 14 warning: deny(warnings) incompatible with previous forbid 17 LL | #![forbid(warnings)] 20 LL | #[deny(warnings)] 26 warning: deny(warnings) incompatible with previous forbid 29 LL | #![forbid(warnings)] 32 LL | #[deny(warnings)] 38 warning: 3 warnings emitted
|
| D | lint-change-warnings.stderr | 2 --> $DIR/lint-change-warnings.rs:5:5 8 --> $DIR/lint-change-warnings.rs:1:9 10 LL | #![deny(warnings)] 12 = note: `#[deny(while_true)]` implied by `#[deny(warnings)]` 15 --> $DIR/lint-change-warnings.rs:15:5 23 --> $DIR/lint-change-warnings.rs:20:5 29 --> $DIR/lint-change-warnings.rs:18:10 31 LL | #[forbid(warnings)] 33 = note: `#[forbid(while_true)]` implied by `#[forbid(warnings)]`
|
| /third_party/cares/cmake/ |
| D | EnableWarnings.cmake | 10 # remove_warnings(... list of warnings ...) 11 # Turn off given list of individual warnings for all targets and subdirectories added after this. 14 # Remove all warning flags, add -w to suppress built-in warnings. 17 # Suppress warnings for the given targets only. 46 # This function can be called in subdirectories, to prune out warnings that they don't want. 47 # vararg: warning flags to remove from list of enabled warnings. All "no" flags after EXPLICIT_DIS… 50 # Ex.: remove_warnings(-Wall -Wdouble-promotion -Wcomment) prunes those warnings flags from the com… 77 # Explicitly suppress all warnings. As long as this flag is the last warning flag, warnings will be 78 # suppressed even if earlier flags enabled warnings. 120 …message(AUTHOR_WARNING "Cannot push warnings for ${lang}, CMAKE_${lang}_FLAGS contains semicolons") [all …]
|
| /third_party/rust/rust/compiler/rustc_target/src/ |
| D | tests.rs | 17 let warnings = Target::from_json(json).unwrap().1; in report_unused_fields() localVariable 18 assert_eq!(warnings.warning_messages().len(), 1); in report_unused_fields() 19 assert!(warnings.warning_messages().join("\n").contains("code-mode")); in report_unused_fields() 36 let warnings = Target::from_json(json).unwrap().1; in report_incorrect_json_type() localVariable 37 assert_eq!(warnings.warning_messages().len(), 1); in report_incorrect_json_type() 38 assert!(warnings.warning_messages().join("\n").contains("link-env-remove")); in report_incorrect_json_type() 55 let warnings = Target::from_json(json).unwrap().1; in no_warnings_for_valid_target() localVariable 56 assert_eq!(warnings.warning_messages().len(), 0); in no_warnings_for_valid_target()
|
| /third_party/python/Lib/test/test_warnings/ |
| D | __init__.py | 17 import warnings as original_warnings 20 py_warnings = import_helper.import_fresh_module('warnings', 22 c_warnings = import_helper.import_fresh_module('warnings', 29 """Use a specific warnings implementation in warning_tests.""" 40 original_warnings = warning_tests.warnings 45 warning_tests.warnings = module 48 warning_tests.warnings = original_warnings 61 self.old_unittest_module = unittest.case.warnings 70 # The 'warnings' module must be explicitly set so that the proper 71 # interaction between _warnings and 'warnings' can be controlled. [all …]
|
| /third_party/python/Lib/unittest/ |
| D | main.py | 6 import warnings 63 failfast = catchbreak = buffer = progName = warnings = testNamePatterns = None 69 buffer=None, warnings=None, *, tb_locals=False): argument 85 if warnings is None and not sys.warnoptions: 87 # print them anyway unless other warnings settings are 88 # specified by the warnings arg or the -W python flag 89 self.warnings = 'default' 91 # here self.warnings is set either to the value passed 92 # to the warnings args or to None. 93 # If the user didn't pass a value self.warnings will [all …]
|
| D | runner.py | 5 import warnings 170 failfast=False, buffer=False, resultclass=None, warnings=None, argument 185 self.warnings = warnings 199 with warnings.catch_warnings(): 200 if self.warnings: 201 # if self.warnings is set, use it to filter all the warnings 202 warnings.simplefilter(self.warnings) 204 # warnings from the deprecated unittest methods to show them 207 # only when self.warnings is None. 208 if self.warnings in ['default', 'always']: [all …]
|
| /third_party/python/Lib/test/libregrtest/ |
| D | save_env.py | 55 'warnings.filters', 'asyncore.socket_map', 62 'files', 'locale', 'warnings.showwarning', 156 warnings = self.try_get_module('warnings') 157 return id(warnings.filters), warnings.filters, warnings.filters[:] 159 warnings = self.get_module('warnings') 160 warnings.filters = saved_filters[1] 161 warnings.filters[:] = saved_filters[2] 285 warnings = self.try_get_module('warnings') 286 return warnings.showwarning 288 warnings = self.get_module('warnings') [all …]
|
| /third_party/cups/man/ |
| D | cupstestppd.1 | 63 Ignores all PCFileName warnings. 75 Report all UIConstraint errors as warnings. 78 Except for size-related options, report all default option errors as warnings. 81 Report all filter errors as warnings. 84 Report all profile errors as warnings. 87 Report all media size errors as warnings. 90 Report all translation errors as warnings. 93 Report all of the previous errors as warnings.
|
| /third_party/typescript/tests/cases/fourslash/ |
| D | jsFileJsdocTypedefTagTypeExpressionCompletion.ts | 31 function warnings(entries: ReadonlyArray<FourSlashInterface.ExpectedCompletionEntryObject>): Readon… function 40 ...warnings(values), 41 ...warnings(typeMembers), 48 ...warnings(types), 49 ...warnings(typeMembers), 56 ...warnings(types), 57 ...warnings(values),
|
| D | jsFileJsdocTypedefTagTypeExpressionCompletion3.ts | 33 const warnings = (names: ReadonlyArray<string>): ReadonlyArray<FourSlashInterface.ExpectedCompletio… constant 41 …...warnings(["Namespace", "SomeType", "x", "x1", "method1", "property1", "method3", "method4", "fo… 48 …...warnings(["Foo", "value", "property1", "method1", "method3", "method4", "foo", "age", "SomeType… 55 …...warnings(["Foo", "value", "property1", "method1", "method3", "method4", "foo", "age", "Namespac… 64 … ...warnings(["Namespace", "SomeType", "method1", "property1", "method3", "method4", "foo"]), 71 …...warnings(["Foo", "value", "property1", "method1", "method3", "method4", "foo", "Namespace", "So… 80 … ...warnings(["Foo", "value", "method1", "foo", "age", "Namespace", "SomeType", "x", "x1"]), 89 …...warnings(["Foo", "value", "property1", "method3", "method4", "foo", "age", "Namespace", "SomeTy…
|
| /third_party/curl/docs/ |
| D | CHECKSRC.md | 23 `-h` shows the help output, that also lists all recognized warnings 35 Lists how to use the script and it lists all existing warnings it has and 37 warnings are: 51 **Ignore certain warnings** section below for details. 131 ### Extended warnings 133 Some warnings are quite computationally expensive to perform, so they are 134 turned off by default. To enable these warnings, place a `.checksrc` file in 136 warnings you are interested in. The format of the file is to enable one 139 Currently these are the extended warnings which can be enabled: 148 ## Ignore certain warnings [all …]
|
| /third_party/skia/m133/src/sksl/codegen/ |
| D | SkSLWGSLValidator.cpp | 22 std::string* warnings) { in validate_wgsl() argument 55 // The program contains warnings. Report them as-is. in validate_wgsl() 57 *warnings = diagFormatter.Format(program.Diagnostics()).Plain(); in validate_wgsl() 62 bool ValidateWGSL(ErrorReporter& reporter, std::string_view wgsl, std::string* warnings) { in ValidateWGSL() argument 63 return validate_wgsl(reporter, wgsl, false, warnings); in ValidateWGSL() 66 bool ValidateWGSLVerbose(ErrorReporter& reporter, std::string_view wgsl, std::string* warnings) { in ValidateWGSLVerbose() argument 67 return validate_wgsl(reporter, wgsl, true, warnings); in ValidateWGSLVerbose()
|
| /third_party/python/Lib/test/ |
| D | test_string_literals.py | 35 import warnings 115 with warnings.catch_warnings(record=True) as w: 116 warnings.simplefilter('always', category=DeprecationWarning) 123 with warnings.catch_warnings(record=True) as w: 124 warnings.simplefilter('error', category=DeprecationWarning) 139 with warnings.catch_warnings(record=True) as w: 140 warnings.simplefilter('always', category=DeprecationWarning) 148 with warnings.catch_warnings(record=True) as w: 149 warnings.simplefilter('error', category=DeprecationWarning) 192 with warnings.catch_warnings(record=True) as w: [all …]
|
| /third_party/rust/rust/src/tools/clippy/.github/workflows/ |
| D | clippy.yml | 53 run: cargo build --features deny-warnings,internal 56 run: cargo test --features deny-warnings,internal 59 run: cargo test --features deny-warnings,internal 63 run: cargo test --features deny-warnings,internal 67 run: cargo test --features deny-warnings 71 run: cargo test --features deny-warnings
|