 C-STRUCT: riff-chunk
     { "riff-chunk-header" "header" }
     { "char[4]" "format" }
-    { "uchar[0]" "body" }
     ;
 
 C-STRUCT: wav-fmt-chunk

USING: alien.c-types alien.syntax audio combinators
combinators.short-circuit io io.binary io.encodings.binary
io.files io.streams.memory kernel locals sequences ;
IN: audio.wav

CONSTANT: RIFF-MAGIC "RIFF"

        { [ dup DATA-MAGIC id= ] [ data! ] }
    } cond ] while drop
    fmt data ;

: verify-wav ( chunk -- )
    { [ RIFF-MAGIC id= ] [ riff-chunk-format WAVE-MAGIC id= ] } 1&&
