Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dir::Tmpname.make_tmpname inconsistent with Ruby 2.2+ #3646

Closed
envygeeks opened this issue Feb 4, 2016 · 1 comment
Closed

Dir::Tmpname.make_tmpname inconsistent with Ruby 2.2+ #3646

envygeeks opened this issue Feb 4, 2016 · 1 comment

Comments

@envygeeks
Copy link

In Ruby 2.1 you had to do:

Dir::Tmpname.make_tmpname(["prefix", ""], nil)
Dir::Tmpname.make_tmpname(["prefix", ".ext"], nil)
Dir::Tmpname.make_tmpname(["", ".ext"], nil)

In 2.2+ the second value of the array is optional so you can do:

Dir::Tmpname.make_tmpname(["prefix"], nil)

if you do not wish to have an extension.

@headius
Copy link
Member

headius commented Feb 13, 2016

Hmm...well Tmpname comes from tmpdir.rb which is just stdlib. I'll try to figure why we differ here.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants