The code exceeds an internal limit on exception handler states (32,768 states). The most common cause is that the function contains a complex expression of user-defined class variables and arithmetic operators.
This article is a derivative work based on http://msdn.microsoft.com/en-us/library/673fh3hz.aspx" title="http://msdn.microsoft.com/en-us/library/673fh3hz.aspx" target="_blank">Fatal Error C1509 which is provided by http://msdn.microsoft.com/en-us/library/60k1461a.aspx" title="http://msdn.microsoft.com/en-us/library/60k1461a.aspx" target="_blank">MSDN Community Content - Visual C++.
Simplify expressions by assigning common subexpressions to temporary variables.
Split the function into smaller functions.