#include "ppg_action.h"
#include "ppg_action_flags.h"
#include "ppg_settings.h"
Go to the source code of this file.
|
#define | PPG_TOKENS(...) |
| Auxiliary macro to simplify passing tokens to functions such as ppg_pattern. More...
|
|
#define PPG_TOKENS |
( |
|
... | ) |
|
Value:
void * PPG_Token
The token type.
Definition: ppg_token.h:38
Auxiliary macro to simplify passing tokens to functions such as ppg_pattern.
- Parameters
-
Token flags.
Enumerator |
---|
PPG_Token_Flags_Pedantic |
Enables pedantic mode for tokens.
|
Returns the action that is associated with a token.
- Parameters
-
token | The token whose action is supposed to be retreived |
- Returns
- The associated action
PPG_Action_Flags_Type ppg_token_get_action_flags |
( |
PPG_Token |
token | ) |
|
Returns the action flags associated with a token.
- Parameters
-
token | The token whose action flags are supposed to be retreived |
- Returns
- The current value of the action flags associated with the token.
PPG_Count ppg_token_get_flags |
( |
PPG_Token |
token | ) |
|
Returns the flags associated with a token.
- Parameters
-
token | The token whose flags are supposed to be retreived |
- Returns
- The current value of the flags associated with the token.
Assigns an action to a token.
- Parameters
-
token | The token to be modified |
action | The action definition to associate with the token |
- Returns
- Returns the value of parameter token to allow for setter-chaining
PPG_Token ppg_token_set_action_flags |
( |
PPG_Token |
token, |
|
|
PPG_Action_Flags_Type |
action_flags |
|
) |
| |
Assigns action flags to a token.
To modify the current state of the action flags of a token, use the function ppg_token_get_action_flags, modify its return value by means of applying bit wise operations and pass it to ppg_token_set_action_flags.
- Parameters
-
token | The token to be modified |
action_flags | The new value of action flags |
- Returns
- Returns the value of parameter token to allow for setter-chaining
Assigns flags to a token.
To modify the current state of the flags of a token, use the function ppg_token_get_flags, modify its return value by means of applying bit wise operations and pass it to ppg_token_set_flags.
- Note
- Be careful when modifying flags manually as different token types support different types flags. Read the documentation of the respective token type carefully before manipulating its flags.
- Parameters
-
token | The token to be modified |
flags | The new value of flags |
- Returns
- Returns the value of parameter token to allow for setter-chaining