Ever since my previous question, I've been running into two issues 
with my SDL_mixer bindings.  The first, is that I get a warning message 
whenever I use the function Mix_GetError() (the definition for this 
function may be found here: 
https://github.com/d4v3y5c0n3s/Goldelish-Engine/blob/master/source/SDL2/SDL_mixer.sats).
  
The warning is as follows:

g_audio_dats.c: In function 'audio_sound_play': 
/home/d4v3y/ATS2-Postiats-0.4.0/ccomp/runtime/pats_ccomp_instrset.h:276:35: 
warning: 
assignment discards 'const' qualifier fr
om pointer target type [-Wdiscarded-qualifiers] 
#define ATSINSmove(tmp, val) (tmp = val)

While this is only a warning, I would still like to know what is going 
wrong here.  I looked at ATS-contrib's SDL binding, and found that the 
SDL_GetError() function there had the exact same problem.  (The file for 
this function definition may be found here: 
https://github.com/githwxi/ATS-Postiats-contrib/blob/master/contrib/SDL2/SATS/SDL_error.sats
)

     The second issue that I'm running into has to do with my 
Mix_FadeInMusic() function (which is defined here: 
https://github.com/d4v3y5c0n3s/Goldelish-Engine/blob/master/source/SDL2/SDL_mixer.sats).
  
When I use this function, I get the following error message:

g_audio_dats.c: In function 'audio_music_play': 
g_audio_dats.c:931:11: error: storage size of 'tmpref41' isn't known 
ATStmpdec(tmpref41, Mix_Music) ; 
          ^~~~~~~~ 
/home/d4v3y/ATS2-Postiats-0.4.0/ccomp/runtime/pats_ccomp_instrset.h:209:33: 
note: 
in definition of macro 'ATStmpdec' 
#define ATStmpdec(tmp, hit) hit tmp 
                                ^~~ 
/home/d4v3y/ATS2-Postiats-0.4.0/ccomp/runtime/pats_ccomp_instrset.h:217:29: 
error: 
dereferencing pointer to incomplete type '
Mix_Music' {aka 'struct _Mix_Music'} 
#define ATSderef(pmv, hit) (*(hit*)pmv)


     The file *where I've been receiving these errors* is available here: 
https://github.com/d4v3y5c0n3s/Goldelish-Engine/blob/master/source/g_audio.dats.
  
My full source code is available on Github here: 
https://github.com/d4v3y5c0n3s/Goldelish-Engine.

     Any help is appreciated, and if you'd like me to provide any more 
information, please ask for it.  Also, if anyone knows of a great resource 
for understanding how the internals of ATS work, please let me know.  I 
have a feeling that if I better understood how ATS worked, I would also 
better understand what to do when I encounter error messages such as these.

-- 
You received this message because you are subscribed to the Google Groups 
"ats-lang-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to ats-lang-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/ats-lang-users/e3db4fac-0969-406f-aaa5-02b3b2145a84%40googlegroups.com.

Reply via email to