3 Replies
      Latest reply on Jul 8, 2015 9:20 PM by ChrisLattner
      OOPer Level 8 Level 8 (5,435 points)

        In Swift 2 this code generates error:

            private lazy var _keyGenerationController = KeyGeneration(nibName: "KeyGeneration", bundle: nil)
        

         

        Removing lazy or explicitly annotating the type suppresses this error:

            private var _keyGenerationController = KeyGeneration(nibName: "KeyGeneration", bundle: nil)
        

        or:

            private lazy var _keyGenerationController: KeyGeneration = KeyGeneration(nibName: "KeyGeneration", bundle: nil)
        

         

        What's happening?