generalize split declaration and add to parameter list to functions