Prolog: minor improvement