environment <- function(fun=NULL) .Internal(environment(fun))