Share via


TokenFlags Enum

Definition

Flags that specify additional information about a given token.

This enumeration supports a bitwise combination of its member values.

public enum class TokenFlags
[System.Flags]
public enum TokenFlags
[<System.Flags>]
type TokenFlags = 
Public Enum TokenFlags
Inheritance
TokenFlags
Attributes

Fields

AssignmentOperator 8192

The token is one of the assignment operators: '=', '+=', '-=', '*=', '/=', '%=' or '??='

AttributeName 4194304

The token names an attribute.

BinaryOperator 256

The token is a binary operator.

BinaryPrecedenceAdd 4

The precedence of the binary operators '+' and '-'.

BinaryPrecedenceBitwise 2

The precedence of the bitwise operators '-band', '-bor', and '-bxor'

BinaryPrecedenceCoalesce 7

The precedence of null coalesce operator '??'.

BinaryPrecedenceComparison 3

The precedence of comparison operators including: '-eq', '-ne', '-ge', '-gt', '-lt', '-le', '-like', '-notlike', '-match', '-notmatch', '-replace', '-contains', '-notcontains', '-in', '-notin', '-split', '-join', '-is', '-isnot', '-as', and all of the case sensitive variants of these operators, if they exists.

BinaryPrecedenceFormat 6

The precedence of the '-f' operator.

BinaryPrecedenceLogical 1

The precedence of the logical operators '-and', '-or', and '-xor'.

BinaryPrecedenceMask 7

A bitmask to get the precedence of binary operators.

BinaryPrecedenceMultiply 5

The precedence of the operators '*', '/', and '%'.

BinaryPrecedenceRange 7

The precedence of the '..' operator.

CanConstantFold 8388608

The token is a valid operator to use when doing constant folding.

CaseSensitiveOperator 1024

The token is a case sensitive operator such as '-ceq' or '-ccontains'.

CommandName 524288

The token names a command in a pipeline.

DisallowedInRestrictedMode 131072

The operator is not allowed in restricted language mode or in the data language.

Keyword 16

The token is a keyword.

MemberName 1048576

The token names a member of a class.

None 0

The token has no flags.

ParseModeInvariant 32768

The token is scanned identically in expression mode or command mode.

PrefixOrPostfixOperator 262144

The token is either a prefix or postfix '++' or '--'.

ScriptBlockBlockName 32

The token is one of the keywords that is a part of a script block: 'begin', 'process', 'end', 'clean', or 'dynamicparam'.

SpecialOperator 4096

The operators '&', '|', and the member access operators ':' and '::'.

StatementDoesntSupportAttributes 16777216

The token is a statement but does not support attributes.

TernaryOperator 2048

The token is a ternary operator '?'.

TokenInError 65536

The token has some error associated with it. For example, it may be a string missing it's terminator.

TypeName 2097152

The token names a type.

UnaryOperator 512

The token is a unary operator.

Applies to