/// <summary> /// Adds the default return statement. /// </summary> /// <param name="contractElement">The contract element.</param> /// <param name="memberTypeReference">The member type reference.</param> private void AddDefaultReturn(LanguageElement contractElement, TypeReferenceExpression memberTypeReference) { Contract.Requires(contractElement != null, "contractElement is null."); Contract.Requires(memberTypeReference != null, "memberTypeReference is null."); var returnValue = !this.CodeRushProxy.Language.IsCSharp ? this.CodeRushProxy.Language.GetNullReferenceExpression() : new DefaultValueExpression(memberTypeReference); var methodReturn = new Return(returnValue); methodReturn.AddCommentNode(new Comment() { Name = RuntimeIgnored, CommentType = CommentType.SingleLine }); contractElement.AddNode(methodReturn); }