added new result_of mode that uses TR1 with a decltype fallback as suggested by Nathan Crookston; fixes #7753