Hi again Sean! I'm sorry it took so long, but I finally was able to test your patch: Am Mittwoch, den 30.03.2011, 13:44 -0400 schrieb Sean McNamara: > FYI, this page is an absolute lifesaver: > http://live.gnome.org/Vala/Manual/Attributes#CCode_Attribute Thanks, that's *very* helpful! > With the attached patch, I get: > > $ valac --pkg=libpulse --vapidir=/usr/share/vala-0.12/vapi test2.vala > test2.vala:2.16-2.40: warning: field `MyClass.map' never used > PulseAudio.ChannelMap map; > ^^^^^^^^^^^^^^^^^^^^^^^^^ > Compilation succeeded - 1 warning(s) Hmm, with the current upstream version (which contains your patch) I get this: $ cat Test.vala class Test : Object { PulseAudio.ChannelMap map; public static void main(){ } } $ valac-0.12 --pkg=libpulse --vapidir=. Test.vala Test.vala:2.2-2.26: warning: field `Test.map' never used PulseAudio.ChannelMap map; ^^^^^^^^^^^^^^^^^^^^^^^^^ /home/alexander/Test.vala.c: In function ?pulse_audio_channel_map_destroy?: /home/alexander/Test.vala.c:50: error: incompatible types when assigning to type ?enum pa_channel_position_t[32]? from type ?void *? error: cc exited with status 256 Compilation failed: 1 error(s), 1 warning(s) $ The attached patch fixes the issue for me: $ valac-0.12 --pkg=libpulse --vapidir=. Test.vala Test.vala:2.2-2.26: warning: field `Test.map' never used PulseAudio.ChannelMap map; ^^^^^^^^^^^^^^^^^^^^^^^^^ Compilation succeeded - 1 warning(s) $ However, I'm not quite certain whether this is the correct solution, since I means hardcoding the array size (constants are not supported). What do you think? Does the current upstream libpulse.vapi file really work for you w/o modifications? Best regards Alexander Kurtz -------------- next part -------------- A non-text attachment was scrubbed... Name: set_array_size.patch Type: text/x-patch Size: 505 bytes Desc: not available URL: <http://lists.freedesktop.org/archives/pulseaudio-discuss/attachments/20110414/8a257bcf/attachment.bin> -------------- next part -------------- A non-text attachment was scrubbed... Name: not available Type: application/pgp-signature Size: 836 bytes Desc: This is a digitally signed message part URL: <http://lists.freedesktop.org/archives/pulseaudio-discuss/attachments/20110414/8a257bcf/attachment.pgp>