mirror of
https://github.com/mutouyun/cpp-ipc.git
synced 2025-12-07 01:06:45 +08:00
fix(msvc): Fix C4138 warning by adding space before commented parameter names
ISSUE: MSVC compiler reports warning C4138: '*/' found outside of comment for patterns like 'void */*p*/' where the pointer asterisk is immediately followed by a comment start. AFFECTED FILES: - include/libipc/mem/new.h (line 30) - src/libipc/platform/win/mutex.h (line 54) - src/libipc/platform/win/semaphore.h (line 53) CHANGES: Changed 'type */*param*/' to 'type * /*param*/' (added space before comment) Examples: - void */*p*/ → void * /*p*/ - char const */*name*/ → char const * /*name*/ This resolves the MSVC warning while maintaining code functionality and keeping the commented-out parameter names for documentation.
This commit is contained in:
parent
52ff081770
commit
874e0b25bc
@ -27,7 +27,7 @@ class LIBIPC_EXPORT block_collector {
|
|||||||
public:
|
public:
|
||||||
virtual ~block_collector() noexcept = default;
|
virtual ~block_collector() noexcept = default;
|
||||||
virtual void *allocate(std::size_t /*bytes*/) noexcept = 0;
|
virtual void *allocate(std::size_t /*bytes*/) noexcept = 0;
|
||||||
virtual void deallocate(void */*p*/, std::size_t /*bytes*/) noexcept = 0;
|
virtual void deallocate(void * /*p*/, std::size_t /*bytes*/) noexcept = 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
/// \brief Matches the appropriate memory block resource based on a specified size.
|
/// \brief Matches the appropriate memory block resource based on a specified size.
|
||||||
|
|||||||
@ -55,7 +55,7 @@ public:
|
|||||||
close();
|
close();
|
||||||
}
|
}
|
||||||
|
|
||||||
static void clear_storage(char const */*name*/) noexcept {
|
static void clear_storage(char const * /*name*/) noexcept {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool lock(std::uint64_t tm) noexcept {
|
bool lock(std::uint64_t tm) noexcept {
|
||||||
|
|||||||
@ -54,7 +54,7 @@ public:
|
|||||||
close();
|
close();
|
||||||
}
|
}
|
||||||
|
|
||||||
static void clear_storage(char const */*name*/) noexcept {
|
static void clear_storage(char const * /*name*/) noexcept {
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wait(std::uint64_t tm) noexcept {
|
bool wait(std::uint64_t tm) noexcept {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user