CompilationUnit.NewSyntaxTree Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Builds a syntax tree containing callables and types,
and attaches the documentation specified by documentation - if any - to each namespace.
public static System.Collections.Immutable.ImmutableArray<Microsoft.Quantum.QsCompiler.SyntaxTree.QsNamespace> NewSyntaxTree (System.Collections.Generic.IEnumerable<Microsoft.Quantum.QsCompiler.SyntaxTree.QsCallable> callables, System.Collections.Generic.IEnumerable<Microsoft.Quantum.QsCompiler.SyntaxTree.QsCustomType> types, System.Collections.Generic.IReadOnlyDictionary<string,System.Linq.ILookup<string,System.Collections.Immutable.ImmutableArray<string>>>? documentation = default);
static member NewSyntaxTree : seq<Microsoft.Quantum.QsCompiler.SyntaxTree.QsCallable> * seq<Microsoft.Quantum.QsCompiler.SyntaxTree.QsCustomType> * System.Collections.Generic.IReadOnlyDictionary<string, System.Linq.ILookup<string, System.Collections.Immutable.ImmutableArray<string>>> -> System.Collections.Immutable.ImmutableArray<Microsoft.Quantum.QsCompiler.SyntaxTree.QsNamespace>
Public Shared Function NewSyntaxTree (callables As IEnumerable(Of QsCallable), types As IEnumerable(Of QsCustomType), Optional documentation As IReadOnlyDictionary(Of String, ILookup(Of String, ImmutableArray(Of String))) = Nothing) As ImmutableArray(Of QsNamespace)
Parameters
- callables
- IEnumerable<QsCallable>
- types
- IEnumerable<QsCustomType>
- documentation
- IReadOnlyDictionary<String,ILookup<String,ImmutableArray<String>>>
Returns
Remarks
All elements within a namespace will be sorted in alphabetical order.