The calculi of lambda-nu-cs conversion: a syntactic theory of control and state in imperative higher-order programming languages