From bd1c464f591d26340f96183ee6f402652e4c38b5 Mon Sep 17 00:00:00 2001 From: Stone Tickle Date: Mon, 31 Jan 2022 07:20:33 -0600 Subject: print warning when using fastyaml loader --- docs/refman/loaderyaml.py | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'docs/refman/loaderyaml.py') diff --git a/docs/refman/loaderyaml.py b/docs/refman/loaderyaml.py index 9f96fa4..e632741 100644 --- a/docs/refman/loaderyaml.py +++ b/docs/refman/loaderyaml.py @@ -295,9 +295,9 @@ class LoaderYAML(LoaderBase): return [module, *objs] def load_impl(self) -> ReferenceManual: - mlog.log('Loading YAML refererence manual') + mlog.log('Loading YAML reference manual') with mlog.nested(): - return ReferenceManual( + manual = ReferenceManual( functions=[self._load_function(x) for x in self.func_dir.iterdir()], objects=mesonlib.listify([ [self._load_object(ObjectType.ELEMENTARY, x) for x in self.elem_dir.iterdir()], @@ -306,3 +306,8 @@ class LoaderYAML(LoaderBase): [self._load_module(x) for x in self.modules_dir.iterdir()] ], flatten=True) ) + + if not self.strict: + mlog.warning('YAML reference manual loaded using the best-effort fastyaml loader. Results are not guaranteed to be stable or correct.') + + return manual -- cgit v1.1