#!/bin/bash
while read A B C
do
if [ "$A" = variableStep ]
then eval "$B; $C"
else echo -e "$chrom $A $((A+span))\t$B"
fi
done <infile
Which can also be written
#!/bin/bash
while read A B C
do [ "$A" = variableStep ] && eval "$B; $C" || echo -e "$chrom $A $((A+span))\t$B"
done <infile maybe the test condition can be [ -n "$C" ] in state of [ "$A" = variableStep ]