From 7d68dd44ff24950ed5d3da6c781ab512334b6e7b Mon Sep 17 00:00:00 2001 From: Mark Stapp Date: Thu, 28 May 2020 12:37:51 -0400 Subject: [PATCH] doc: encourage const in the developer doc Add a little text about using 'const' in the dev doc. Signed-off-by: Mark Stapp --- doc/developer/workflow.rst | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/doc/developer/workflow.rst b/doc/developer/workflow.rst index 6885a41e0f..49fa4fe832 100644 --- a/doc/developer/workflow.rst +++ b/doc/developer/workflow.rst @@ -1021,6 +1021,15 @@ JSON Output All JSON keys are to be camelCased, with no spaces. +Use of const +^^^^^^^^^^^^ + +Please consider using ``const`` when possible: it's a useful hint to +callers about the limits to side-effects from your apis, and it makes +it possible to use your apis in paths that involve ``const`` +objects. If you encounter existing apis that *could* be ``const``, +consider including changes in your own pull-request. + .. _documentation: -- 2.39.5