cmd/godoc: fix minor bug in FormatSelections.
cmd/godoc: fix minor bug in FormatSelections.

FormatSelections tries to call a nil function value if lw is nil
and the final entry in the selections array is non-nil. Luckily,
this doesn't actually happen in practice since godoc doesn't use
this combination (no line numbers, but with selections).

R=gri
CC=gobot, golang-dev
http://codereview.appspot.com/6488106

Committer: Robert Griesemer <a6752097faebf1f02d80107d77a9be009089afe3@golang.org>

scirelli/scirelli-go,bryanxu/go-zh,rdp/rogerpack2005-golang,mhennings/marcohennings-go,glycerine/jeaten-go-arrayof-structof,rdp/rogerpack2005-golang,glycerine/jeaten-go-arrayof-structof,bryanxu/go-zh,webfd/go-zh,scirelli/scirelli-go,scirelli/scirelli-go,webfd/go-zh,d0f/go-zh,rdp/rogerpack2005-golang,rdp/rogerpack2005-golang,bryanxu/go-zh,d0f/go-zh,scirelli/scirelli-go,mhennings/marcohennings-go,sanjosh/sanjos100-tipc,mhennings/marcohennings-go,rflanagan/reginaldflanagan-project1,d0f/go-zh,glycerine/jeaten-go-arrayof-structof,webfd/go-zh,sanjosh/sanjos100-tipc,d0f/go-zh,bryanxu/go-zh,rdp/rogerpack2005-golang,glycerine/jeaten-go-arrayof-structof,rflanagan/reginaldflanagan-project1,sanjosh/sanjos100-tipc,sanjosh/sanjos100-tipc,rflanagan/reginaldflanagan-project1,mhennings/marcohennings-go,rflanagan/reginaldflanagan-project1,bryanxu/go-zh,d0f/go-zh,mhennings/marcohennings-go,rflanagan/reginaldflanagan-project1,webfd/go-zh,webfd/go-zh,bryanxu/go-zh,glycerine/jeaten-go-arrayof-structof,mhennings/marcohennings-go,mhennings/marcohennings-go,webfd/go-zh,glycerine/jeaten-go-arrayof-structof,sanjosh/sanjos100-tipc,rflanagan/reginaldflanagan-project1,sanjosh/sanjos100-tipc,webfd/go-zh,d0f/go-zh,mhennings/marcohennings-go,rdp/rogerpack2005-golang,scirelli/scirelli-go,d0f/go-zh,bryanxu/go-zh,bryanxu/go-zh,rdp/rogerpack2005-golang,glycerine/jeaten-go-arrayof-structof,rflanagan/reginaldflanagan-project1,webfd/go-zh,sanjosh/sanjos100-tipc,scirelli/scirelli-go,scirelli/scirelli-go,rdp/rogerpack2005-golang,glycerine/jeaten-go-arrayof-structof,d0f/go-zh,sanjosh/sanjos100-tipc,rflanagan/reginaldflanagan-project1,scirelli/scirelli-go