File tree Expand file tree Collapse file tree 1 file changed +5
-7
lines changed
python/ql/src/semmle/python Expand file tree Collapse file tree 1 file changed +5
-7
lines changed Original file line number Diff line number Diff line change @@ -209,14 +209,12 @@ module API {
209209
210210 /**
211211 * Gets a node corresponding to an import of module `m`.
212+ *
213+ * Note: You should only use this predicate for top level modules. If you want nodes corresponding to a submodule,
214+ * you should use `.getMember` on the parent module. For example, for nodes corresponding to the module `foo.bar`,
215+ * use `moduleImport("foo").getMember("bar")`.
212216 */
213- Node moduleImport ( string m ) {
214- result = Impl:: MkModuleImport ( m )
215- or
216- exists ( string before_dot , string after_dot | before_dot + "." + after_dot = m |
217- result = moduleImport ( before_dot ) .getMember ( after_dot )
218- )
219- }
217+ Node moduleImport ( string m ) { result = Impl:: MkModuleImport ( m ) }
220218
221219 /**
222220 * Provides the actual implementation of API graphs, cached for performance.
You can’t perform that action at this time.
0 commit comments