Merge branch 'feature/issue-676-generalize-operandsandpartials' of https://github.com/stan-dev/stan into feature/issue-676-generalize-operandsandpartials