2 Replies Latest reply on Oct 26, 2010 8:16 AM by JustinMclean

    Heavy Constructor Warning

    JustinMclean Level 1

      Hi there,


      I can see it's a good principle to not have heavy constructors. But does anyone know if this the message about the compiler not compiling constructors is actually true?


      "HeavyConstructor. Constructor must be as lightweight as possible. No control statement allowed, whereas a cyclomatic complexe of 2 has been detected. The Just-In-Time compiler does not compile constructors. Make them as lightweight as possible, or move the complexity of the code to a method called by the constructor. Then the complexity will be compiled by the JIT"