optimizer: transform ((begin ... proc) x) to (begin ... (proc x))

Currently the optimizer can convert ((let (...) ... proc) x) to
(let (...) ... (proc x)). This is useful especially if proc can be
inlined. Extend this to begin's forms.
optimizer: another ((begin ... proc) x) to (begin ... (proc x))

The tranformation this time applies before optimization of the rator
and complements Gustavo's variant, which applies after optimization of
the rator.