Skip to content

Commit 2d48b15

Browse files
authored
Allow loading of CPGs produced by js2cpg into joern (#1009)
1 parent 14bc175 commit 2d48b15

1 file changed

Lines changed: 16 additions & 0 deletions

File tree

  • semanticcpg/src/main/scala/io/shiftleft/semanticcpg/layers

semanticcpg/src/main/scala/io/shiftleft/semanticcpg/layers/Scpg.scala

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,22 @@ class Scpg(optionsUnused: LayerCreatorOptions = null) extends LayerCreator {
110110
new CfgDominatorPass(cpg),
111111
new CdgPass(cpg),
112112
)
113+
case Languages.JAVASCRIPT =>
114+
Iterator(
115+
new ArgumentCompat(cpg),
116+
new MethodInstCompat(cpg),
117+
new MethodStubCreator(cpg),
118+
new MethodDecoratorPass(cpg),
119+
new CapturingLinker(cpg),
120+
new Linker(cpg),
121+
new FileNameCompat(cpg),
122+
new FileLinker(cpg),
123+
new ContainsEdgePass(cpg),
124+
new MethodExternalDecoratorPass(cpg),
125+
new CfgDominatorPass(cpg),
126+
new CdgPass(cpg),
127+
new NamespaceCreator(cpg),
128+
)
113129
case _ => Iterator()
114130
}
115131
}

0 commit comments

Comments
 (0)