[libcamera-devel] [RFC PATCH 2/6] utils: ipc: Prevent struct constructors from being parsed by doxygen
Laurent Pinchart
laurent.pinchart at ideasonboard.com
Mon May 24 15:17:45 CEST 2021
Hi Paul,
Thank you for the patch.
On Mon, May 24, 2021 at 05:40:25PM +0900, Paul Elder wrote:
> Currently the generated constructors for structs defined in mojom files
> is being parsed by mojom. As the parameters are simply the struct
> members, they are already documented, and the documentation of the
> constructor is pointless. Protect them against being parsed by doxygen.
>
> Signed-off-by: Paul Elder <paul.elder at ideasonboard.com>
Looks good to me, but this change is already present in master :-)
> ---
> .../generators/libcamera_templates/definition_functions.tmpl | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/utils/ipc/generators/libcamera_templates/definition_functions.tmpl b/utils/ipc/generators/libcamera_templates/definition_functions.tmpl
> index cdd75f89..94bb4918 100644
> --- a/utils/ipc/generators/libcamera_templates/definition_functions.tmpl
> +++ b/utils/ipc/generators/libcamera_templates/definition_functions.tmpl
> @@ -25,6 +25,7 @@ enum {{enum.mojom_name}} {
> struct {{struct.mojom_name}}
> {
> public:
> +#ifndef __DOXYGEN__
> {{struct.mojom_name}}() {%- if struct|has_default_fields %}
> :{% endif %}
> {%- for field in struct.fields|with_default_values -%}
> @@ -44,6 +45,8 @@ public:
> {%- endfor %}
> {
> }
> +#endif
> +
> {% for field in struct.fields %}
> {{field|name}} {{field.mojom_name}};
> {%- endfor %}
--
Regards,
Laurent Pinchart
More information about the libcamera-devel
mailing list