Skip to content

Commit 48b95f3

Browse files
committed
Rust: Move OperationImpl to internal/OperationImpl.qll.
1 parent 09dc7fc commit 48b95f3

File tree

2 files changed

+30
-22
lines changed

2 files changed

+30
-22
lines changed

rust/ql/lib/codeql/rust/elements/Operation.qll

Lines changed: 1 addition & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -2,28 +2,7 @@
22
* Provides classes for operations.
33
*/
44

5-
private import rust
5+
import internal.OperationImpl
66
private import codeql.rust.elements.internal.ExprImpl::Impl as ExprImpl
77

8-
/**
9-
* INTERNAL: This module contains the customizable definition of `Operation` and should not
10-
* be referenced directly.
11-
*/
12-
module OperationImpl {
13-
/**
14-
* An operation, for example `&&`, `+=`, `!` or `*`.
15-
*/
16-
abstract class Operation extends ExprImpl::Expr {
17-
/**
18-
* Gets the operator name of this operation, if it exists.
19-
*/
20-
abstract string getOperatorName();
21-
22-
/**
23-
* Gets an operand of this operation.
24-
*/
25-
abstract Expr getAnOperand();
26-
}
27-
}
28-
298
final class Operation = OperationImpl::Operation;
Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
/**
2+
* Provides classes for operations.
3+
*
4+
* INTERNAL: Do not use.
5+
*/
6+
7+
private import rust
8+
private import codeql.rust.elements.internal.ExprImpl::Impl as ExprImpl
9+
10+
/**
11+
* INTERNAL: This module contains the customizable definition of `Operation` and should not
12+
* be referenced directly.
13+
*/
14+
module OperationImpl {
15+
/**
16+
* An operation, for example `&&`, `+=`, `!` or `*`.
17+
*/
18+
abstract class Operation extends ExprImpl::Expr {
19+
/**
20+
* Gets the operator name of this operation, if it exists.
21+
*/
22+
abstract string getOperatorName();
23+
24+
/**
25+
* Gets an operand of this operation.
26+
*/
27+
abstract Expr getAnOperand();
28+
}
29+
}

0 commit comments

Comments
 (0)