Making shared.R generic