Music has a lot of these. A fugue subject may traverse the boundaries between two metric groupings, and between two clear sections of the form.
There are also non-contiguous examples. Smack in the middle of Wagner's Tristan und Isolde you hear the final theme that signals they are about to win the main boss battle. Then one of the NPCs screams right before the final chord. The audience instead hears the danger signal and realizes it was a fake boss and there's another two hours of game play. Only when Isolde beats the final boss at the end do we get the final chord.
It also affects the digital markup of music. Music can't be expressed with a tree structure as there is lots of overlap.
A simple example is a slur. It crosses bar lines. <bar1> ... <slur> ... </bar1> ... </slur> <bar2> uhoh!
In fact there are many mutually incompatible hierarchies in music engraving.
It's funny though MusicXML is a popular interchange format, but internally looks nothing like what one would naively expect.