From 640b17ec788f26b9e56762e1ecad898ffb13bbe7 Mon Sep 17 00:00:00 2001 From: Matthew Costabile Date: Tue, 5 May 2026 07:41:36 -0400 Subject: [PATCH] Add UseMemoDirective and UseNoMemoDirective classes --- javascript/ql/lib/semmle/javascript/Stmt.qll | 26 ++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/javascript/ql/lib/semmle/javascript/Stmt.qll b/javascript/ql/lib/semmle/javascript/Stmt.qll index db0d79de7bd..6a757cc1d6c 100644 --- a/javascript/ql/lib/semmle/javascript/Stmt.qll +++ b/javascript/ql/lib/semmle/javascript/Stmt.qll @@ -435,6 +435,32 @@ module Directive { UseClientDirective() { this.getDirectiveText() = "use client" } } + /** + * A `use memo` directive. + * + * Example: + * + * ``` + * "use memo"; + * ``` + */ + class UseMemoDirective extends KnownDirective { + UseMemoDirective() { this.getDirectiveText() = "use memo" } + } + + /** + * A `use no memo` directive. + * + * Example: + * + * ``` + * "use no memo"; + * ``` + */ + class UseNoMemoDirective extends KnownDirective { + UseNoMemoDirective() { this.getDirectiveText() = "use no memo" } + } + /** * A `use cache` directive. *