Opened 7 years ago
Closed 7 years ago
#737 closed defect (fixed)
PCUT_ASSERT_NULL does not accept const pointer
| Reported by: | Jiri Svoboda | Owned by: | |
|---|---|---|---|
| Priority: | major | Milestone: | 0.8.0 |
| Component: | helenos/lib/other | Version: | mainline |
| Keywords: | pcut | Cc: | |
| Blocker for: | Depends on: | ||
| See also: |
Description
The following code:
const void *a = NULL; PCUT_ASSERT_NULL(a);
will produce a warning like
../../lib/pcut/include/pcut/asserts.h:150:25: error: initialization discards 'const' qualifier from pointer target type [-Werror=discarded-qualifiers]
Change History (1)
comment:1 by , 7 years ago
| Keywords: | pcut added |
|---|---|
| Resolution: | → fixed |
| Status: | new → closed |
Note:
See TracTickets
for help on using tickets.

Funny, this happens only in
PCUT_ASSERT_NULLnot withPCUT_ASSERT_NOT_NULL.Anyway, fixed upstream in 1ccf66e and in HelenOS via 4b54bd956b3a.