Beispiel #1
0
        /// <summary>
        /// Creates a new syntax token identical to this one without the specified annotations.
        /// </summary>
        public SyntaxToken WithoutAnnotations(IEnumerable <SyntaxAnnotation> annotations)
        {
            if (annotations == null)
            {
                throw new ArgumentNullException("annotations");
            }

            if (this.Node != null)
            {
                return(new SyntaxToken(
                           parent: null,
                           token: _token.WithoutAnnotationsGreen(annotations),
                           position: 0, index: 0
                           ));
            }

            return(default(SyntaxToken));
        }