Fix prototype for user defined subroutines.

Fixes #1357