Fraunhofer-AISEC / cpg

A library to extract Code Property Graphs from C/C++, Java, Go, Python, Ruby and every other language through LLVM-IR.
https://fraunhofer-aisec.github.io/cpg/
Apache License 2.0
246 stars 59 forks source link

Fixing placement of inferred record declarations #1515

Closed oxisto closed 1 month ago

oxisto commented 1 month ago

Before this PR, we inferred all record declarations into the global scope, even though we knew (because of the FQN) that the record is part of another "name" (e.g. a namespace). This PR fixes that and correctly places the inferred record in the extracted scope of its FQN.

sonarcloud[bot] commented 1 month ago

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
86.6% Coverage on New Code
0.0% Duplication on New Code

See analysis details on SonarCloud