Scans through the source code and assembly references of a Compilation to locate the (Item)NotNullAttribute and (Item)CanBeNullAttribute types.
        public NullabilityAttributeSymbols GetSymbols(Compilation compilation,
            CancellationToken cancellationToken = default(CancellationToken))
        {
            Guard.NotNull(compilation, nameof(compilation));

            var scanner = new CompilationAttributeScanner();
            return scanner.Scan(compilation, cancellationToken);
        }
Ejemplo n.º 2
0
        public NullabilityAttributeSymbols GetSymbols(Compilation compilation,
                                                      CancellationToken cancellationToken = default(CancellationToken))
        {
            Guard.NotNull(compilation, nameof(compilation));

            var scanner = new CompilationAttributeScanner();

            return(scanner.Scan(compilation, cancellationToken));
        }