mesa/st: Make st_convert_image(_from_unit) declaration match definition
authorMichel Dänzer <mdaenzer@redhat.com>
Fri, 14 Apr 2023 09:30:14 +0000 (11:30 +0200)
committerMarge Bot <emma+marge@anholt.net>
Tue, 18 Apr 2023 09:49:44 +0000 (09:49 +0000)
commit0f7d01cdbe03936d51a29fa57bee04991537ee7e
tree2cdd1dc9b2ad1a80c7ba739b3566b1e789aa5d38
parent92a47ba1ae40990b837923162788331e4cadec2c
mesa/st: Make st_convert_image(_from_unit) declaration match definition

Pointed out by GCC 13:

../src/mesa/state_tracker/st_atom_image.c:51:1: warning: conflicting types for ‘st_convert_image’ due to enum/integer mismatch; have ‘void(const struct st_context *, const struct gl_image_unit *, struct pipe_image_view *, enum gl_access_qualifier)’ [-Wenum-int-mismatch]
   51 | st_convert_image(const struct st_context *st, const struct gl_image_unit *u,
      | ^~~~~~~~~~~~~~~~
In file included from ../src/mesa/state_tracker/st_atom_image.c:41:
../src/mesa/state_tracker/st_texture.h:242:1: note: previous declaration of ‘st_convert_image’ with type ‘void(const struct st_context *, const struct gl_image_unit *, struct pipe_image_view *, unsigned int)’
  242 | st_convert_image(const struct st_context *st, const struct gl_image_unit *u,
      | ^~~~~~~~~~~~~~~~
../src/mesa/state_tracker/st_atom_image.c:134:1: warning: conflicting types for ‘st_convert_image_from_unit’ due to enum/integer mismatch; have ‘void(const struct st_context *, struct pipe_image_view *, GLuint,  enum gl_access_qualifier)’ {aka ‘void(const struct st_context *, struct pipe_image_view *, unsigned int,  enum gl_access_qualifier)’} [-Wenum-int-mismatch]
  134 | st_convert_image_from_unit(const struct st_context *st,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~
../src/mesa/state_tracker/st_texture.h:246:1: note: previous declaration of ‘st_convert_image_from_unit’ with type ‘void(const struct st_context *, struct pipe_image_view *, GLuint,  unsigned int)’ {aka ‘void(const struct st_context *, struct pipe_image_view *, unsigned int,  unsigned int)’}
  246 | st_convert_image_from_unit(const struct st_context *st,
      | ^~~~~~~~~~~~~~~~~~~~~~~~~~

Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/22517>
src/mesa/state_tracker/st_texture.h