mirror of
https://github.com/github/codeql.git
synced 2026-04-29 18:55:14 +02:00
Pull usage count into where clause
This commit is contained in:
@@ -11,12 +11,13 @@ import APIUsage
|
||||
import ExternalAPI
|
||||
import semmle.code.java.GeneratedFiles
|
||||
|
||||
from ExternalAPI api
|
||||
from ExternalAPI api, int usages
|
||||
where
|
||||
not api.isTestLibrary() and
|
||||
supportKind(api) = "source"
|
||||
select api.asCsv(api) as csv,
|
||||
strictcount(Call c |
|
||||
c.getCallee() = api and
|
||||
not c.getFile() instanceof GeneratedFile
|
||||
) as Usages order by Usages desc
|
||||
supportKind(api) = "source" and
|
||||
usages =
|
||||
strictcount(Call c |
|
||||
c.getCallee() = api and
|
||||
not c.getFile() instanceof GeneratedFile
|
||||
)
|
||||
select api.asCsv(api) as csv, usages order by usages desc
|
||||
|
||||
Reference in New Issue
Block a user