コード例 #1
0
        public override void VisitLockStatement(LockStatementSyntax node)
        {
            var lockBinder = new LockBinder(_enclosing, node);

            AddToMap(node, lockBinder);

            StatementSyntax statement       = node.Statement;
            var             statementBinder = lockBinder.WithAdditionalFlags(BinderFlags.InLockBody);

            if (statementBinder != lockBinder)
            {
                AddToMap(statement, statementBinder);
            }

            VisitPossibleEmbeddedStatement(statement, statementBinder);
        }
コード例 #2
0
ファイル: LocalBinderFactory.cs プロジェクト: shashinh/roslyn
        public override void VisitLockStatement(LockStatementSyntax node)
        {
            var patternBinder = new PatternVariableBinder(node, _enclosing);
            var lockBinder    = new LockBinder(patternBinder, node);

            AddToMap(node, lockBinder);

            Visit(node.Expression, lockBinder);

            StatementSyntax statement       = node.Statement;
            var             statementBinder = lockBinder.WithAdditionalFlags(BinderFlags.InLockBody);

            if (statementBinder != lockBinder)
            {
                AddToMap(statement, statementBinder);
            }

            VisitPossibleEmbeddedStatement(statement, statementBinder);
        }
コード例 #3
0
        public override void VisitLockStatement(LockStatementSyntax node)
        {
            var lockBinder = new LockBinder(_enclosing, node);
            AddToMap(node, lockBinder);

            StatementSyntax statement = node.Statement;
            var statementBinder = lockBinder.WithAdditionalFlags(BinderFlags.InLockBody);
            if (statementBinder != lockBinder)
            {
                AddToMap(statement, statementBinder);
            }

            VisitPossibleEmbeddedStatement(statement, statementBinder);
        }
コード例 #4
0
ファイル: LocalBinderFactory.cs プロジェクト: CAPCHIK/roslyn
        public override void VisitLockStatement(LockStatementSyntax node)
        {
            var patternBinder = new PatternVariableBinder(node, _enclosing);
            var lockBinder = new LockBinder(patternBinder, node);
            AddToMap(node, lockBinder);

            Visit(node.Expression, lockBinder);

            StatementSyntax statement = node.Statement;
            var statementBinder = lockBinder.WithAdditionalFlags(BinderFlags.InLockBody);
            if (statementBinder != lockBinder)
            {
                AddToMap(statement, statementBinder);
            }

            VisitPossibleEmbeddedStatement(statement, statementBinder);
        }