CodeQL library for Go
codeql/go-all 0.7.12 (changelog, source)
Search

Class BuiltinFunction

A built-in function.

Import path

import semmle.go.Scopes

Direct supertypes

Indirect supertypes

Predicates

isPure

Holds if this function is pure, that is, it has no observable side effects and no non-determinism.

isVariadic

Holds if this function is variadic.

mayHaveSideEffects

Holds if this function has no observable side effects.

mayPanic

Holds if calling this function may cause a runtime panic.

mustPanic

Holds if calling this function always causes a runtime panic.

Inherited predicates

getACall

Gets a call to this function.

from Function
getAParameter

Gets a parameter of this function.

from Function
getARead

Gets a data-flow node that reads the value of this entity.

from ValueEntity
getAReference

Gets a reference to this entity.

from Entity
getAResult

Gets a result variable of this function.

from Function
getAWrite

Gets a control-flow node that updates the value of this entity.

from ValueEntity
getBody

Gets the body of this function, if any.

from Function
getDeclaration

Gets the declaring identifier for this entity.

from Entity
getFuncDecl

Gets the declaration of this function, if any.

from Function
getName

Gets the name of this entity.

from Entity
getNumParameter

Gets the number of parameters of this function.

from Function
getNumResult

Gets the number of results of this function.

from Function
getPackage

Gets the package in which this entity is declared, if any.

from Entity
getParameter

Gets the ith parameter of this function.

from Function
getParameterType

Gets the type of the ith parameter of this function.

from Function
getQualifiedName

Gets the qualified name of this entity, if any.

from Entity
getResult

Gets the ith reslt variable of this function.

from Function
getResultType

Gets the type of the ith result of this function.

from Function
getScope

Gets the scope in which this entity is declared, if any.

from Entity
getType

Gets the type of this entity.

from Entity
hasLocationInfo

Holds if this element is at the specified location. The location spans column startcolumn of line startline to column endcolumn of line endline in file filepath. For more information, see Locations.

from Entity
hasQualifiedName

Holds if this entity is declared in a package with path pkg and has the given name.

from Entity
mayReturnNormally

Holds if this function may return without panicking, exiting the process, or looping forever.

from Function
toString

Gets a textual representation of this entity.

from Entity