-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Multiple/Single Argument Operator
Planend definiton
Currently operators can only be added if theri accept only two arguments.
Thats because off the way user input and validation is implemented.
But with this change the operators would be defined in this way:
operations.py:
OPERATIONS = {
"<tag>": {
"title": "Addition",
"symbol": "+",
"args": (
"addend a",
"addend b"
),
"action": lambda a, b: a + b,
"result-name": "sum"
},
}| Key | Description |
|---|---|
| Tag | Used for internal logic to indicate format errors on tags |
| Title | Indicates the calculation used, displayed in the help menu |
| Symbol | The symbol that triggers the operator for use |
| Args | A list of arguments requested from the user and passed in the specified order to the Callable |
| Action | A Callable whose return value is the result |
| Result Name | The name given to the result (e.g., "product") |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request