Simplified by removing dependency on SFINAE