当前位置: 首页>>代码示例>>C#>>正文


C# CSharp.FlowAnalysisContext类代码示例

本文整理汇总了C#中Mono.CSharp.FlowAnalysisContext的典型用法代码示例。如果您正苦于以下问题:C# FlowAnalysisContext类的具体用法?C# FlowAnalysisContext怎么用?C# FlowAnalysisContext使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


FlowAnalysisContext类属于Mono.CSharp命名空间,在下文中一共展示了FlowAnalysisContext类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			source.FlowAnalysis (fc);
			((FieldExpr) target).SetFieldAssigned (fc);
		}
开发者ID:nobled,项目名称:mono,代码行数:5,代码来源:assign.cs

示例2: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			base.FlowAnalysis (fc);
			method_group.FlowAnalysis (fc);

			if (conditional_access_receiver)
				fc.ConditionalAccessEnd ();
		}
开发者ID:psni,项目名称:mono,代码行数:8,代码来源:delegate.cs

示例3: FlowAnalysis

		public void FlowAnalysis (FlowAnalysisContext fc)
		{
			foreach (var arg in args)
				arg.FlowAnalysis (fc);
		}
开发者ID:santosh-pai,项目名称:mono,代码行数:5,代码来源:argument.cs

示例4: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			invoke.FlowAnalysis (fc);
		}
开发者ID:caomw,项目名称:mono,代码行数:4,代码来源:dynamic.cs

示例5: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			source.FlowAnalysis (fc);

			if (target is ArrayAccess || target is IndexerExpr || target is PropertyExpr)
				target.FlowAnalysis (fc);
		}
开发者ID:dyxu,项目名称:vimrc,代码行数:7,代码来源:assign.cs

示例6: FlowAnalysis

		public void FlowAnalysis (FlowAnalysisContext fc)
		{
			bool has_out = false;
			foreach (var arg in args) {
				if (arg.ArgType == Argument.AType.Out) {
					has_out = true;
					continue;
				}

				arg.FlowAnalysis (fc);
			}

			if (!has_out)
				return;

			foreach (var arg in args) {
				if (arg.ArgType != Argument.AType.Out)
					continue;

				arg.FlowAnalysis (fc);
			}
		}
开发者ID:dyxu,项目名称:vimrc,代码行数:22,代码来源:argument.cs

示例7: IsFullyInitialized

		// <summary>
		//   A struct's constructor must always assign all fields.
		//   This method checks whether it actually does so.
		// </summary>
		public bool IsFullyInitialized (FlowAnalysisContext fc, VariableInfo vi, Location loc)
		{
			if (struct_info == null)
				return true;

			bool ok = true;
			for (int i = 0; i < struct_info.Count; i++) {
				var field = struct_info.Fields[i];

				if (!fc.IsStructFieldDefinitelyAssigned (vi, field.Name)) {
					var bf = field.MemberDefinition as Property.BackingFieldDeclaration;
					if (bf != null) {
						if (bf.Initializer != null)
							continue;

						fc.Report.Error (843, loc,
							"An automatically implemented property `{0}' must be fully assigned before control leaves the constructor. Consider calling the default struct contructor from a constructor initializer",
							field.GetSignatureForError ());

						ok = false;
						continue;
					}

					fc.Report.Error (171, loc,
						"Field `{0}' must be fully assigned before control leaves the constructor",
						field.GetSignatureForError ());
					ok = false;
				}
			}

			return ok;
		}
开发者ID:psni,项目名称:mono,代码行数:36,代码来源:flowanalysis.cs

示例8: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc) {
			base.FlowAnalysis (fc);
			method_group.FlowAnalysis (fc);
		}
开发者ID:hultqvist,项目名称:mono,代码行数:4,代码来源:delegate.cs

示例9: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			source.FlowAnalysis (fc);

			if (target is ArrayAccess || target is IndexerExpr) {
				target.FlowAnalysis (fc);
				return;
			}

			var pe = target as PropertyExpr;
			if (pe != null && !pe.IsAutoPropertyAccess)
				target.FlowAnalysis (fc);
		}
开发者ID:JokerMisfits,项目名称:linux-packaging-mono,代码行数:13,代码来源:assign.cs

示例10: FlowAnalysis

		public virtual void FlowAnalysis (FlowAnalysisContext fc, List<MovableArgument> movable = null)
		{
			bool has_out = false;
			foreach (var arg in args) {
				if (arg.ArgType == Argument.AType.Out) {
					has_out = true;
					continue;
				}

				if (movable == null) {
					arg.FlowAnalysis (fc);
					continue;
				}

				var ma = arg as MovableArgument;
				if (ma != null && !movable.Contains (ma))
					arg.FlowAnalysis (fc);
			}

			if (!has_out)
				return;

			foreach (var arg in args) {
				if (arg.ArgType != Argument.AType.Out)
					continue;

				arg.FlowAnalysis (fc);
			}
		}
开发者ID:frje,项目名称:SharpLang,代码行数:29,代码来源:argument.cs

示例11: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			// We are reachable, mark block body reachable too
			MarkReachable (new Reachability ());

			CheckReachableExit (fc.Report);

			var das = fc.BranchDefiniteAssignment ();
			var prev_pb = fc.ParametersBlock;
			fc.ParametersBlock = Block;
			var da_ontrue = fc.DefiniteAssignmentOnTrue;
			var da_onfalse = fc.DefiniteAssignmentOnFalse;

			block.FlowAnalysis (fc);

			fc.ParametersBlock = prev_pb;
			fc.DefiniteAssignment = das;
			fc.DefiniteAssignmentOnTrue = da_ontrue;
			fc.DefiniteAssignmentOnFalse = da_onfalse;
		}
开发者ID:erik-kallen,项目名称:NRefactory,代码行数:20,代码来源:anonymous.cs

示例12: DoFlowAnalysis

			protected override bool DoFlowAnalysis (FlowAnalysisContext fc)
			{
				return false;
			}
开发者ID:erik-kallen,项目名称:NRefactory,代码行数:4,代码来源:anonymous.cs

示例13: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			side_effect.FlowAnalysis (fc);
		}
开发者ID:genoher,项目名称:mono,代码行数:4,代码来源:constant.cs

示例14: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			if (argument_list != null)
				argument_list.FlowAnalysis (fc);
		}
开发者ID:0xb1dd1e,项目名称:NRefactory,代码行数:5,代码来源:method.cs

示例15: FlowAnalysis

		public override void FlowAnalysis (FlowAnalysisContext fc)
		{
			var da = conditional_access_receiver ? fc.BranchDefiniteAssignment () : null;

			base.FlowAnalysis (fc);
			method_group.FlowAnalysis (fc);

			if (conditional_access_receiver)
				fc.DefiniteAssignment = da;
		}
开发者ID:hongling0,项目名称:mono,代码行数:10,代码来源:delegate.cs


注:本文中的Mono.CSharp.FlowAnalysisContext类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。