Return to readline version 6.x in Homebrew to fix Postgresql?
Just reinstall postgresql94
package, the PostgreSQL 9.4 will use the new readline
package:
brew reinstall postgresql94
To answer the specific question.
You can switch between version of installed brew packages which are still around locally as explained in this question: Homebrew install specific version of formula?
To downgrade to readline 6.x the following command worked for me:
brew switch readline 6.3.8