summaryrefslogtreecommitdiff
path: root/PythonAPIDocumentation.md
diff options
context:
space:
mode:
authorPeter LaFosse <peter@vector35.com>2022-01-28 11:00:19 -0500
committerPeter LaFosse <peter@vector35.com>2022-02-17 08:42:55 -0500
commit2e47077a2b32184f6b021abd01150a4c669b759d (patch)
treed07b299b444441b6c1b99796e69fefdeabcbb151 /PythonAPIDocumentation.md
parent925323f286e2ff2b866c2c65cdcc342cafa4afe7 (diff)
Add additional unit tests for function.py
Move calls to Free into finally blocks format function.py and api_test.py
Diffstat (limited to 'PythonAPIDocumentation.md')
-rw-r--r--PythonAPIDocumentation.md9
1 files changed, 5 insertions, 4 deletions
diff --git a/PythonAPIDocumentation.md b/PythonAPIDocumentation.md
index 95e5e9dd..61f59251 100644
--- a/PythonAPIDocumentation.md
+++ b/PythonAPIDocumentation.md
@@ -155,10 +155,11 @@ DataVariable objects have been greatly enhanced in Binary Ninja 3.0. In the core
Prior to 3.0 a frequent question was: "Through the API how do you set the name of a DataVariable?" The answer was always "You don't, instead create a symbol at that location." This is the same way function names are handled. Although this abstraction serves us well it doesn't make for an intuitive API, thus DataVariable now has a convenient method for setting the variables name and name.
```python
-data_var = bv.get_data_var_at(here)
-data_var.name
-data_var.name = 'foobar'
-data_var.name
+>>> data_var = bv.get_data_var_at(here)
+>>> data_var.name
+
+>>> data_var.name = 'foobar'
+>>> data_var.name
'foobar'
```
Or if you prefer to give the DataVariable a more complete symbol.