From 47ac4dd1dcdaab4f6cbd0312a63df060225747e0 Mon Sep 17 00:00:00 2001 From: Mathias Vorreiter Pedersen Date: Mon, 17 Nov 2025 19:21:37 +0000 Subject: [PATCH] C++: Add 'nomagic' to 'getParameter'. --- cpp/ql/lib/semmle/code/cpp/Function.qll | 2 ++ 1 file changed, 2 insertions(+) diff --git a/cpp/ql/lib/semmle/code/cpp/Function.qll b/cpp/ql/lib/semmle/code/cpp/Function.qll index 8ddb07a868e..10b156e3fb6 100644 --- a/cpp/ql/lib/semmle/code/cpp/Function.qll +++ b/cpp/ql/lib/semmle/code/cpp/Function.qll @@ -171,12 +171,14 @@ class Function extends Declaration, ControlFlowNode, AccessHolder, @function { * Gets the nth parameter of this function. There is no result for the * implicit `this` parameter, and there is no `...` varargs pseudo-parameter. */ + pragma[nomagic] Parameter getParameter(int n) { params(unresolveElement(result), underlyingElement(this), n, _) } /** * Gets a parameter of this function. There is no result for the implicit * `this` parameter, and there is no `...` varargs pseudo-parameter. */ + pragma[nomagic] Parameter getAParameter() { params(unresolveElement(result), underlyingElement(this), _, _) } /**