Feature #8098

Add __DIR__ to compliment __FILE__

Added by Hal Brodigan over 2 years ago. Updated almost 2 years ago.



There should be a DIR constant to compliment FILE.

Related issues

Duplicates Ruby trunk - Feature #3346: __DIR__ revisted Closed 05/26/2010


#1 Updated by Charlie Somerville over 2 years ago

IIRC (({DIR})) has already been shot down because of concerns that introducing a new keyword might break things.

However I would like to see a (({file})) method to complement (({dir})), (({method})), etc.

#2 Updated by Eric Hodel over 2 years ago

  • Status changed from Open to Rejected

#3 Updated by Hal Brodigan almost 2 years ago

I concur with Charlie Somerville. It does seem asymetrical that there is a __FILE__ constant, but no __file__ method.

Also available in: Atom PDF