mirror of
https://github.com/github/codeql.git
synced 2026-04-29 18:55:14 +02:00
JS: Deprecate PathExpr and related classes
This commit is contained in:
@@ -92,13 +92,13 @@ private predicate hasDefaultExport(ES2015Module mod) {
|
||||
class ImportDeclaration extends Stmt, Import, @import_declaration {
|
||||
override ES2015Module getEnclosingModule() { result = this.getTopLevel() }
|
||||
|
||||
override PathExpr getImportedPath() { result = this.getChildExpr(-1) }
|
||||
|
||||
/**
|
||||
* INTERNAL USE ONLY. DO NOT USE.
|
||||
*/
|
||||
string getRawImportPath() { result = this.getChildExpr(-1).getStringValue() }
|
||||
|
||||
override Expr getImportedPathExpr() { result = this.getChildExpr(-1) }
|
||||
|
||||
/**
|
||||
* Gets the object literal passed as part of the `with` (or `assert`) clause in this import declaration.
|
||||
*
|
||||
@@ -155,7 +155,7 @@ class ImportDeclaration extends Stmt, Import, @import_declaration {
|
||||
}
|
||||
|
||||
/** A literal path expression appearing in an `import` declaration. */
|
||||
private class LiteralImportPath extends PathExpr, ConstantString {
|
||||
deprecated private class LiteralImportPath extends PathExpr, ConstantString {
|
||||
LiteralImportPath() { exists(ImportDeclaration req | this = req.getChildExpr(-1)) }
|
||||
|
||||
override string getValue() { result = this.getStringValue() }
|
||||
@@ -736,7 +736,7 @@ abstract class ReExportDeclaration extends ExportDeclaration {
|
||||
}
|
||||
|
||||
/** A literal path expression appearing in a re-export declaration. */
|
||||
private class LiteralReExportPath extends PathExpr, ConstantString {
|
||||
deprecated private class LiteralReExportPath extends PathExpr, ConstantString {
|
||||
LiteralReExportPath() { exists(ReExportDeclaration bred | this = bred.getImportedPath()) }
|
||||
|
||||
override string getValue() { result = this.getStringValue() }
|
||||
|
||||
Reference in New Issue
Block a user