yamlWarningCallback top-level property
A callback for emitting a warning.
In a very few cases, the YAML spec indicates that an implementation should emit a warning. To do so, it calls this callback. The default implementation prints a message using print.
Implementation
// ignore: prefer_function_declarations_over_variables
YamlWarningCallback yamlWarningCallback = (message, [SourceSpan? span]) {
// TODO(nweiz): Print to stderr with color when issue 6943 is fixed and
// dart:io is available.
if (span != null) message = span.message(message);
print(message);
};