WillAyd commented on code in PR #41359:
URL: https://github.com/apache/arrow/pull/41359#discussion_r1580217566
##########
cpp/src/arrow/device.h:
##########
@@ -150,9 +150,10 @@ class ARROW_EXPORT Device : public
std::enable_shared_from_this<Device>,
/// @param release_fn a function to call during destruction, `nullptr` or
/// a no-op function can be passed to indicate ownership is maintained
/// externally
- virtual Result<std::shared_ptr<Stream>> WrapStream(
- [[maybe_unused]] void* device_stream,
- [[maybe_unused]] Stream::release_fn_t release_fn) {
+ virtual Result<std::shared_ptr<Stream>> WrapStream(void* device_stream,
+ Stream::release_fn_t
release_fn) {
+ ARROW_UNUSED(device_stream);
+ ARROW_UNUSED(release_fn);
Review Comment:
Here's an MRE.
test.cc:
```cpp
#define ARG_UNUSED(x)
/// @brief A function
///
/// @param foo - this is not really used
void SomeFunction(void ARG_UNUSED(foo)) {
return;
}
```
Doxyfile:
```
PROJECT_NAME = foo
INPUT = test.cc
MACRO_EXPANSION = YES
PREDEFINED = ARG_UNUSED(x)=x
```
`doxygen -d Preprocessor` output:
```
Doxygen version used: 1.9.1
Searching for include files...
Searching for example files...
Searching for images...
Searching for dot files...
Searching for msc files...
Searching for dia files...
Searching for files to exclude
Searching INPUT for files to process...
Reading and parsing tag files
Parsing files
Preprocessing /home/willayd/Desktop/test.cc...
Preprocessor output of /home/willayd/Desktop/test.cc (size: 134 bytes):
---------
00001 #define ARG_UNUSED(x)
00002
00003 /// @brief A function
00004 ///
00005 /// @param foo - this is not really used
00006 void SomeFunction(void foo ) {
00007 return;
00008 }
00009
---------
Macros accessible in this file (/home/willayd/Desktop/test.cc):
---------
ARG_UNUSED
---------
```
`clang++ test.cc -Wdocumentation -shared` output:
```
test.cc:5:12: warning: parameter 'foo' not found in the function declaration
[-Wdocumentation]
/// @param foo - this is not really used
^~~
1 warning generated.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]