public static IReturnStatement Return(this IBlockStatementParent blockParent, IClassPropertyMember returnValue)
 {
     return(blockParent.Return(returnValue.GetReference()));
 }
 public static IYieldReturnStatement YieldReturn(this IBlockStatementParent blockParent, IClassPropertyMember returnValue)
 {
     return(blockParent.YieldReturn((IExpression)returnValue.GetReference()));
 }
        private void CreateEndOfFilePresentImpl(IIntermediateClassType resultClass, IInterfaceIndexerMember initialIndexer, IInterfaceType readOnlyCollection, IClassPropertyMember countProp)
        {
            EndOFilePresentImpl             = resultClass.Properties.Add(new TypedName("EndOFilePresent", RuntimeCoreType.Boolean, assembly.IdentityManager), true, false);
            EndOFilePresentImpl.SummaryText = string.Format(@"Returns whether the @s:{0}Symbols.{1}; is present within the @s:{2};", this.compiler.Source.Options.AssemblyName, this.compiler.LexicalSymbolModel.GetEofIdentityField().Name, resultClass.Name);
            var mainBlock    = EndOFilePresentImpl.GetMethod;
            var countPropRef = countProp.GetReference(new SpecialReferenceExpression(SpecialReferenceKind.This));
            var countCheck   = mainBlock.If(countPropRef.GreaterThan(0));

            countCheck.Return(this.commonSymbolBuilder.Identity.GetReference(initialIndexer.GetIndexerSignatureReference <IInterfaceIndexerMember, IInterfaceType>(new SpecialReferenceExpression(SpecialReferenceKind.This), new IExpression[] { countPropRef.Subtract(1) })).EqualTo(compiler.LexicalSymbolModel.GetEofIdentityField().GetReference()));
            mainBlock.Return(IntermediateGateway.FalseValue);
        }