autowarefoundation / autoware

Autoware - the world's leading open-source software project for autonomous driving
https://www.autoware.org/
Apache License 2.0
8.6k stars 2.89k forks source link

C++ code should be in the autoware namespace #4117

Closed esteve closed 3 months ago

esteve commented 5 months ago

Checklist

Description

Current C++ code does not follow a unified convention for namespaces. According to the Google C++ Style Guide (which the ROS Style guide is based upon) code must be under a namespace that matches the name of the project https://google.github.io/styleguide/cppguide.html#Namespaces

Purpose

Possible approaches

The most straightforward approach is to just add all software to the autoware namespace, however, we might want to also add another subnamespace for the component the code is part of (i.e. perception, localization, etc.)

Definition of done

All the code is under either the autoware namespace or a subnamespace of it

esteve commented 5 months ago

Related discussion: https://github.com/orgs/autowarefoundation/discussions/4097#discussioncomment-8347308

xmfcx commented 5 months ago

Over 2 options: 1) autoware::package_name 2) autoware::component_name::package_name

My vote would be on Option 1. Reasons:

cc. @yukkysaito @mitsudome-r @isamu-takagi @TakaHoribe

esteve commented 5 months ago

@xmfcx I agree, I prefer to keep hierarchies as flat as possible

esteve commented 3 months ago

Closing, superseded by #4569