add line numbers to nodes when parsing

closes #691