mirror of
https://github.com/github/codeql.git
synced 2026-04-30 11:15:13 +02:00
Rust: test cases for comments
This commit is contained in:
@@ -0,0 +1,7 @@
|
||||
| comments.rs:1:1:3:2 | Comment | getParent: | comments.rs:1:1:9:1 | foo | getText: | /** \n* A doc comment\n*/ |
|
||||
| comments.rs:6:17:6:34 | Comment | getParent: | comments.rs:6:17:8:16 | nested | getText: | // print some text |
|
||||
| comments.rs:7:3:7:31 | Comment | getParent: | comments.rs:6:17:8:16 | nested | getText: | /// This is a nested function |
|
||||
| gen_comment.rs:1:1:1:36 | Comment | getParent: | gen_comment.rs:1:1:7:2 | SourceFile | getText: | // generated by codegen, do not edit |
|
||||
| gen_comment.rs:4:5:4:30 | Comment | getParent: | gen_comment.rs:3:25:7:1 | StmtList | getText: | // A comment. For example: |
|
||||
| gen_comment.rs:5:5:5:24 | Comment | getParent: | gen_comment.rs:3:25:7:1 | StmtList | getText: | // this is a comment |
|
||||
| gen_comment.rs:6:5:6:29 | Comment | getParent: | gen_comment.rs:3:25:7:1 | StmtList | getText: | /// This is a doc comment |
|
||||
10
rust/ql/test/extractor-tests/generated/Comment/comments.rs
Normal file
10
rust/ql/test/extractor-tests/generated/Comment/comments.rs
Normal file
@@ -0,0 +1,10 @@
|
||||
/**
|
||||
* A doc comment
|
||||
*/
|
||||
|
||||
fn foo() {
|
||||
print("foo"); // print some text
|
||||
/// This is a nested function
|
||||
fn nested() {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user