/// <summary> /// Returns the type of symbol, assuming parameter is a symbol. /// </summary> public static SymbolType GetSymbolType(string arg) { if (Keywords.IsKeyword(arg)) { return(SymbolType.Keyword); } if (Operators.IsOperator(arg)) { return(SymbolType.Operator); } if (Types.IsType(arg)) { return(SymbolType.Type); } throw new InvalidEnumArgumentException("Argument is not a valid symbol"); }
public static bool IsSymbol(string arg) { return(Keywords.IsKeyword(arg) || Operators.IsOperator(arg) || Types.IsType(arg)); }
public static bool IsOperator(string arg) { return(Operators.IsOperator(arg)); }