#################################################################### ## These are two tests to show how deeply nested the new vars are # #------------------------------------------------------------------# test() # should be fine test2() # should produce error after "Inside Test2" datDir # should produce error. test <- function() { dosDir(wrkDir, T) print ("Inside Test") print(dataDir) } test2 <- function() { test() print ("Inside Test2") print(dataDir) }