My conjecture is that the bug is due to the use of SQL functions in the check. However, the [docs](https://www.postgresql.org/docs/9.4/ddl-constraints.html) on constraints do not mention any limitations on using such SQL functions in checks. If such limitations exist, they should be mentioned in the docs.
You should read the most current version of the documentation for a feature before reporting a bug. In this case the warnings you desired have been added to more recently versions of the documentation.
Short answer, check constraints are designed to work only with data present on the table upon which they are defined. Use triggers to work with other tables.