Skip to content

Warning: Discarding const from pointers in fletcher32 #725

Closed

Description

@jakirkham

Seeing warnings about discarding const from pointers in fletcher32 on CI :

  building 'numcodecs.fletcher32' extension
  /home/runner/miniconda3/envs/test/bin/aarch64-conda-linux-gnu-cc -ftree-vectorize -fPIC -fstack-protector-strong -fno-plt -O3 -pipe -isystem /home/runner/miniconda3/envs/test/include -DNDEBUG -D_FORTIFY_SOURCE=2 -O2 -isystem /home/runner/miniconda3/envs/test/include -fPIC -Inumcodecs -I/home/runner/miniconda3/envs/test/include/python3.12 -c numcodecs/fletcher32.c -o /tmp/tmpp_01vogx.build-temp/numcodecs/fletcher32.o
  numcodecs/fletcher32.c: In function '__pyx_pf_9numcodecs_10fletcher32_10Fletcher32_encode':
  numcodecs/fletcher32.c:18290:17: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
  18290 |   __pyx_v_b_ptr = (&(*((uint8_t const  *) ( /* dim=0 */ ((char *) (((uint8_t const  *) __pyx_v_b_mv.data) + __pyx_t_8)) ))));
        |                 ^
  numcodecs/fletcher32.c: In function '__pyx_pf_9numcodecs_10fletcher32_10Fletcher32_2decode':
  numcodecs/fletcher32.c:18649:17: warning: assignment discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
  18649 |   __pyx_v_b_ptr = (&(*((uint8_t const  *) ( /* dim=0 */ ((char *) (((uint8_t const  *) __pyx_v_b_mv.data) + __pyx_t_7)) ))));
        |                 ^

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions