makeSpanList function

Make a list of spans