On the Goldie Dimension of Rings and Modules