1
0
Fork 0

Merge pull request #2962 from ZehMatt/fix-docgen

Cleanup documentation for Script::Misc
This commit is contained in:
Duncan Ogilvie 2022-10-18 22:04:46 +02:00 committed by GitHub
commit 7d10c587c9
Signed by: GitHub
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 26 additions and 10 deletions

View File

@ -11,8 +11,12 @@ namespace Script
/// Evaluates an expression and returns the result. Analagous to using the Command field in x64dbg.
///
/// Expressions can consist of memory locations, registers, flags, API names, labels, symbols, variables etc.
///
/// Example: bool success = ParseExpression("[esp+8]", &val)
/// <example>
/// Shows how to read from stack at esp+8
/// <code>
/// bool success = ParseExpression("[esp+8]", &amp;val)
/// </code>
/// </example>
/// </summary>
/// <param name="expression">The expression to evaluate.</param>
/// <param name="value">The result of the expression.</param>
@ -21,9 +25,12 @@ namespace Script
/// <summary>
/// Returns the address of a function in the debuggee's memory space.
///
/// Example: duint addr = RemoteGetProcAddress("kernel32.dll", "GetProcAddress")
/// </summary>
/// <example>
/// <code>
/// duint addr = RemoteGetProcAddress("kernel32.dll", "GetProcAddress")
/// </code>
/// </example>
/// <param name="module">The name of the module.</param>
/// <param name="api">The name of the function.</param>
/// <returns>The address of the function in the debuggee.</returns>
@ -31,9 +38,12 @@ namespace Script
/// <summary>
/// Returns the address for a label created in the disassembly window.
///
/// Example: duint addr = ResolveLabel("sneaky_crypto")
/// </summary>
/// <example>
/// <code>
/// duint addr = ResolveLabel("sneaky_crypto")
/// </code>
/// </example>
/// <param name="label">The name of the label to resolve.</param>
/// <returns>The memory address for the label.</returns>
SCRIPT_EXPORT duint ResolveLabel(const char* label);
@ -44,18 +54,24 @@ namespace Script
/// Note: this allocation is in the debugger, not the debuggee.
///
/// Memory allocated using this function should be Free'd after use.
///
/// Example: void* addr = Alloc(0x100000)
/// </summary>
/// <example>
/// <code>
/// void* addr = Alloc(0x100000)
/// </code>
/// </example>
/// <param name="size">Number of bytes to allocate.</param>
/// <returns>A pointer to the newly allocated memory.</returns>
SCRIPT_EXPORT void* Alloc(duint size);
/// <summary>
/// Frees memory previously allocated by Alloc.
///
/// Example: Free(addr)
/// </summary>
/// <example>
/// <code>
/// Free(addr)
/// </code>
/// </example>
/// <param name="ptr">Pointer returned by Alloc.</param>
/// <returns>Nothing.</returns>
SCRIPT_EXPORT void Free(void* ptr);