The ability to choose the right tool for the job is an important skill. Choosing a less productive language makes me wonder as an interviewer whether you'd choose less productive tools on the job, like trying to write C++ or Java code to parse and format files when someone can be orders of magnitude faster using shell scripts or a scripting language.
There are two exceptions I would make for candidates that use C, C++, or Java on a problem that could be more quickly solved with a language like Ruby or Python:
If you're a fresh college grad who hasn't picked up a scripting language, I tend to be more lenient and evaluate whether I think you can pick one up quickly on the job.
If you're more experienced, really proficient at C, C++, or Java, and can solve a problem as quickly as a good programmer who uses Python or Ruby, then that's a strong a skill to have, and I'll take into account that it'd probably be easy for you to pick up a scripting language. Still, there would be a lingering doubt in my mind wondering why you didn't learn a more productive language over the years, since you would've been able to solve the problem that much more quickly.
All that said, there are probably certain interview situations where using a non-scripting language might be desirable. If you're interviewing for a search company or a company that focuses on iOS or Android development, using C++, Objective-C, Java, or whatever the core language is at the company would certainly help demonstrate that you could be effective on the job quickly. If you don't know a scripting language well, it's better to use a language you're proficient at, though it'd be even better to just get proficient at a scripting language. Ultimately, you want to pick the programming language that most effectively demonstrates that you'd be productive. My advice would be to ask your interviewer if he or she has a preference, and if not, to choose the most productive programming language for the problem.