diff options
-rw-r--r-- | src/main.rs | 30 |
1 files changed, 15 insertions, 15 deletions
diff --git a/src/main.rs b/src/main.rs index 4bcc7a5..eb1e241 100644 --- a/src/main.rs +++ b/src/main.rs @@ -191,60 +191,60 @@ fn node_value<'a>(class: &str, data: &'a [u8]) -> IResult<&'a [u8], NodeValue<'a let (r, appver) = p_appversion(&data)?; Ok((r, NodeValue::Version(appver))) }, - "PArrangement\0" => { + "PArrangement" => { let (r, arr) = p_arrangement(&data)?; Ok((r, NodeValue::Arrangement(arr))) }, - "MRoot\0" | - "MTrackList\0" => { + "MRoot" | + "MTrackList" => { let (r, v) = counted_vec(&data)?; Ok((r, NodeValue::Raw(v))) }, - "MInstrumentTrackEvent\0" => { + "MInstrumentTrackEvent" => { let (r, e) = m_instrument_track_event(&data)?; Ok((r, NodeValue::InstrumentTrackEvent(e))) }, - "MTempoTrackEvent\0" => { + "MTempoTrackEvent" => { let (r, e) = m_tempo_track_event(&data)?; Ok((r, NodeValue::TempoTrackEvent(e))) }, - "MSignatureTrackEvent\0" => { + "MSignatureTrackEvent" => { let (r, e) = m_signature_track_event(&data)?; Ok((r, NodeValue::SignatureTrackEvent(e))) }, - "MMidiPartEvent\0" => { + "MMidiPartEvent" => { let (r, v) = count(be_u8, 30)(data)?; Ok((r, NodeValue::MidiPartEvent(v))) }, - "MMidiPart\0" => { + "MMidiPart" => { let (r, v) = m_midi_part(&data)?; Ok((r, NodeValue::MidiPart(v))) }, - "MMidiNote\0" => { + "MMidiNote" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiNote(v))) }, - "MMidiPolyPressure\0" => { + "MMidiPolyPressure" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiPolyPressure(v))) }, - "MMidiAfterTouch\0" => { + "MMidiAfterTouch" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiAfterTouch(v))) }, - "MMidiProgramChange\0" => { + "MMidiProgramChange" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiProgramChange(v))) }, - "MMidiController\0" => { + "MMidiController" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiController(v))) }, - "MMidiPitchBend\0" => { + "MMidiPitchBend" => { let (r, v) = be_u32(data)?; Ok((r, NodeValue::MidiPitchBend(v))) }, - "MMidiSysex\0" => { + "MMidiSysex" => { let sep = vec![0xff, 0xff, 0xff, 0xff]; let (r, v) = take_until(sep.as_slice())(data)?; Ok((r, NodeValue::MidiSysex(v.to_vec()))) |