public ParsedSourceCode Build()
        {
            ApplyNullability();

            string sourceText = GetCompleteSourceText();

            IList <string> nestedTypes = nullabilityAttributes?.NestedTypes ?? new string[0];

            return(new ParsedSourceCode(sourceText, sourceFilename, externalAnnotationsBuilder.Build(),
                                        ImmutableHashSet.Create(references.ToArray()), nestedTypes, codeNamespaceImportExpected, true));
        }