NVIDIA / cccl

CUDA Core Compute Libraries
https://nvidia.github.io/cccl/
Other
1.26k stars 163 forks source link

Useless semicolons #826

Open lahwaacz opened 1 year ago

lahwaacz commented 1 year ago

Compiling with -Wextra-semi shows some warnings due to unnecessary semicolons in Thrust code base:

/opt/cuda/include/thrust/iterator/detail/universal_categories.h:45:78: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   45 |   operator forward_host_iterator_tag () {return forward_host_iterator_tag();};
      |                                                                              ^
      |                                                                              -
/opt/cuda/include/thrust/iterator/detail/universal_categories.h:47:82: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   47 |   operator forward_device_iterator_tag () {return forward_device_iterator_tag();};
      |                                                                                  ^
      |                                                                                  -
/opt/cuda/include/thrust/iterator/detail/universal_categories.h:53:90: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   53 |   operator bidirectional_host_iterator_tag () {return bidirectional_host_iterator_tag();};
      |                                                                                          ^
      |                                                                                          -
/opt/cuda/include/thrust/iterator/detail/universal_categories.h:55:94: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   55 |   operator bidirectional_device_iterator_tag () {return bidirectional_device_iterator_tag();};
      |                                                                                              ^
      |                                                                                              -
/opt/cuda/include/thrust/iterator/detail/universal_categories.h:75:90: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   75 |   operator random_access_host_iterator_tag () {return random_access_host_iterator_tag();};
      |                                                                                          ^
      |                                                                                          -
/opt/cuda/include/thrust/iterator/detail/universal_categories.h:77:94: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   77 |   operator random_access_device_iterator_tag () {return random_access_device_iterator_tag();};
      |                                                                                              ^
      |                                                                                              -
In file included from /opt/cuda/include/thrust/detail/allocator/temporary_allocator.inl:20,
                 from /opt/cuda/include/thrust/detail/allocator/temporary_allocator.h:83,
                 from /opt/cuda/include/thrust/detail/temporary_array.h:41,
                 from /opt/cuda/include/thrust/system/detail/generic/scan_by_key.inl:26,
                 from /opt/cuda/include/thrust/system/detail/generic/scan_by_key.h:142,
                 from /opt/cuda/include/thrust/detail/scan.inl:27,
                 from /opt/cuda/include/thrust/scan.h:1560,
                 from /opt/cuda/include/thrust/system/detail/generic/reduce_by_key.inl:37,
                 from /opt/cuda/include/thrust/system/detail/generic/reduce_by_key.h:87,
                 from /opt/cuda/include/thrust/detail/reduce.inl:28,
                 from /opt/cuda/include/thrust/reduce.h:781:
/opt/cuda/include/thrust/system/detail/bad_alloc.h:44:48: warning: extra ‘;’ after in-class function definition [-Wextra-semi]
   44 |     inline virtual ~bad_alloc(void) throw () {};
      |                                                ^
      |                                                -
lahwaacz commented 10 months ago

A year later, is there any progress?

miscco commented 10 months ago

Unfortunately not.

Due to time constraints we have to prioritize our workload. I am marking this as a good first issue tough, as this does not seem like an issue that needs a maintainer to fix.

eriktedhamre commented 9 months ago

Hello, I'm interested in contributing and feel like this is a good issue. I do however feel like I'm missing a lot of information that is taken for granted. Which makes it hard to start. Any tips?

I have read the various .md files.

jrhemstad commented 9 months ago

A year later, is there any progress?

As of https://github.com/NVIDIA/cccl/pull/531, users should no longer see warnings from CCCL headers. Can you try as of the latest release?

lahwaacz commented 9 months ago

@jrhemstad Was it actually released? #531 was merged in October, but the last release is from September...

Also, when will this appear as part of a CUDA release?