AddRange() public method

Adds a set of nodes to the block
public AddRange ( IEnumerable nodes ) : void
nodes IEnumerable
return void
Example #1
0
        /// <summary>
        /// Create a sequential block of nodes
        /// </summary>
        public static BlockNode Block(SourceLocation location, params SyntaxTreeNode[] nodes)
        {
            var block = new BlockNode
            {
	            Location = location
            };
            block.AddRange(nodes);
            return block;
        }
Example #2
0
 /// <summary>
 /// Create a sequential block of nodes
 /// </summary>
 public static BlockNode Block(params SyntaxTreeNode[] nodes)
 {
     var block = new BlockNode();
     block.AddRange(nodes);
     return block;
 }