Пример #1
0
        public static void Validate(SemanticModel semanticModel, IDiagnosticWriter diagnosticWriter)
        {
            var visitor = new IntegerValidatorVisitor(semanticModel, diagnosticWriter);

            // visiting writes diagnostics in some cases
            visitor.Visit(semanticModel.SourceFile.ProgramSyntax);
        }
Пример #2
0
        public static void Validate(ProgramSyntax programSyntax, IDiagnosticWriter diagnosticWriter)
        {
            var visitor = new IntegerValidatorVisitor(diagnosticWriter);

            // visiting writes diagnostics in some cases
            visitor.Visit(programSyntax);
        }