From cd51601349e900b4c875e0da16ea937f51d84450 Mon Sep 17 00:00:00 2001 From: kevin Date: Wed, 18 May 2016 13:09:27 -0400 Subject: [PATCH] cmMidi.h : Added paren's to macro cmMidiIsNoteOff() to clarify precedence. --- cmMidi.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmMidi.h b/cmMidi.h index ec3dbb9..b6f4859 100644 --- a/cmMidi.h +++ b/cmMidi.h @@ -89,7 +89,7 @@ extern "C" { #define cmMidiIsChStatus( s ) (kNoteOffMdId <= (s) && (s) < kSysExMdId) #define cmMidiIsNoteOn( s ) ( kNoteOnMdId <= (s) && (s) <= (kNoteOnMdId + kMidiChCnt) ) -#define cmMidiIsNoteOff( s, d1 ) ( cmMidiIsNoteOn(s) && (d1)==0 || kNoteOffMdId <= (s) && (s) <= (kNoteOffMdId + kMidiChCnt) ) +#define cmMidiIsNoteOff( s, d1 ) ( (cmMidiIsNoteOn(s) && (d1)==0) || (kNoteOffMdId <= (s) && (s) <= (kNoteOffMdId + kMidiChCnt)) ) #define cmMidiIsCtl( s ) ( kCtlMdId <= (s) && (s) <= (kCtlMdId + kMidiChCnt) ) #define cmMidiIsSustainPedal( s, d0 ) ( kCtlMdId <= (s) && (s) <= (kCtlMdId + kMidiChCnt) && (d0)== kSustainCtlMdId )