Merge "Dirty hack to get CHR ruleset resolved before functions using them"