Skip to content

Commit fb738f2

Browse files
committed
Rust: Update creating-path-queries.rst.
1 parent 3b1d6cd commit fb738f2

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

docs/codeql/writing-codeql-queries/creating-path-queries.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ You should use the following template:
6060
*/
6161
6262
import <language>
63-
// For some languages (Java/C++/Python/Swift) you need to explicitly import the data flow library, such as
63+
// For some languages (Java/C++/Python/Rust/Swift) you need to explicitly import the data flow library, such as
6464
// import semmle.code.java.dataflow.DataFlow or import codeql.swift.dataflow.DataFlow
6565
...
6666
@@ -125,7 +125,7 @@ Declaring sources and sinks
125125
You must provide information about the ``source`` and ``sink`` in your path query. These are objects that correspond to the nodes of the paths that you are exploring.
126126
The name and the type of the ``source`` and the ``sink`` must be declared in the ``from`` statement of the query, and the types must be compatible with the nodes of the graph computed by the ``edges`` predicate.
127127

128-
If you are querying C/C++, C#, Go, Java/Kotlin, JavaScript/TypeScript, Python, or Ruby code (and you have used ``import MyFlow::PathGraph`` in your query), the definitions of the ``source`` and ``sink`` are accessed via the module resulting from the application of the ``Global<..>`` module in the data flow library. You should declare both of these objects in the ``from`` statement.
128+
If you are querying C/C++, C#, Go, Java/Kotlin, JavaScript/TypeScript, Python, Ruby or Rust code (and you have used ``import MyFlow::PathGraph`` in your query), the definitions of the ``source`` and ``sink`` are accessed via the module resulting from the application of the ``Global<..>`` module in the data flow library. You should declare both of these objects in the ``from`` statement.
129129
For example:
130130

131131
.. code-block:: ql
@@ -146,7 +146,7 @@ The configuration module must be defined to include definitions of sources and s
146146
- ``isSource()`` defines where data may flow from.
147147
- ``isSink()`` defines where data may flow to.
148148

149-
For more information on using the configuration class in your analysis see the sections on global data flow in ":ref:`Analyzing data flow in C/C++ <analyzing-data-flow-in-cpp>`," ":ref:`Analyzing data flow in C# <analyzing-data-flow-in-csharp>`," and ":ref:`Analyzing data flow in Python <analyzing-data-flow-in-python>`."
149+
For more information on using the configuration class in your analysis see the sections on global data flow in ":ref:`Analyzing data flow in C/C++ <analyzing-data-flow-in-cpp>`," ":ref:`Analyzing data flow in C# <analyzing-data-flow-in-csharp>`," ":ref:`Analyzing data flow in Python <analyzing-data-flow-in-python>`," and ":ref:`Analyzing data flow in Rust <analyzing-data-flow-in-rust>`."
150150

151151
You can also create a configuration for different frameworks and environments by extending the ``Configuration`` class. For more information, see ":ref:`Types <defining-a-class>`" in the QL language reference.
152152

0 commit comments

Comments
 (0)