Expand description
Type inference for Java class-file bytecode.
Use infer_class for the default analysis configuration, or Inferer
when analysis limits or strict diagnostic handling need to be customized.
The returned ClassInference exposes inferred method, local-variable, and
operand-stack types without requiring a JDK, Java runtime, or external class
hierarchy. Use infer_classes to analyze a caller-supplied batch of class
files.
Class names use the JVM internal form, such as java/lang/String.
Structs§
- Class
Hierarchy - An in-memory
TypeHierarchybuilt solely from caller-supplied class files. - Class
Inference - Type-inference results for one Java class file.
- Class
Inferences - Type-inference results for a caller-supplied batch of class files.
- Class
Name - A JVM internal class name.
- Diagnostic
- A recoverable condition observed while inferring types.
- Diagnostic
Location - Location associated with an analysis diagnostic.
- Field
Summaries - In-memory static-field value summaries supplied by the caller.
- Generic
Class Segment - A nested class segment in a generic class type.
- Generic
Class Signature - Parsed class generic signature.
- Generic
Class Type - A parsed generic class type.
- Generic
Method Signature - Parsed method generic signature.
- Generic
Parameter - Formal parameters and bounds from a class or method signature.
- Generic
Signature - A generic JVM signature preserved from a
Signatureattribute. - Inference
Config - Configuration for a class-file type-inference run.
- Inferer
- A reusable class-file type inferer.
- Instruction
Inference - Inferred abstract state at one bytecode instruction.
- Integral
Type Set - The source-level primitive types still compatible with an integral JVM value.
- Method
Descriptor - A parsed JVM method descriptor.
- Method
Inference - Type-inference results for one method.
- Method
Summaries - In-memory method-return summaries supplied by the caller.
- Operand
Expectation - A verifier-derived type requirement for one operand-stack value.
Enums§
- Descriptor
Error - Error returned when parsing a JVM type or method descriptor.
- Diagnostic
Kind - Category of a condition observed during analysis.
- Diagnostic
Severity - Severity assigned to an analysis diagnostic.
- Dynamic
Call Kind - Statically recognized kind of an
invokedynamiccall site. - Error
- Error returned when a class file cannot be analyzed.
- Generic
Argument - An argument in a generic type argument list.
- Generic
Type - A parsed JVM field type that preserves generic arguments.
- Generic
Wildcard - A Java wildcard bound.
- Inferred
Type - Abstract JVM type inferred for a local variable or operand-stack value.
- Method
Invocation Kind - JVM member-invocation dispatch encoded by a bytecode instruction.
- Name
Error - Error returned when parsing a JVM internal class name.
- Operand
Constraint - The JVM type condition required for an instruction operand.
- Primitive
Type - A JVM primitive type from a field or method descriptor.
- Reference
Type - Inferred state for a JVM reference value.
- Return
Type - A JVM method return descriptor.
- Type
Descriptor - A non-void JVM field type descriptor.
Traits§
- Field
Summary Resolver - Resolves a caller-supplied inferred value type for one static field read.
- Method
Summary Resolver - Resolves a caller-supplied inferred return type for one member invocation.
- Type
Hierarchy - Supplies direct supertypes for optional reference-type refinement.
Functions§
- infer_
class - Infers types from one complete Java class file using
InferenceConfig::default. - infer_
classes - Infers types from caller-supplied Java class files using
InferenceConfig::default.