Skip to main content

verify_method

Function verify_method 

Source
pub fn verify_method<C: VerificationContext>(
    class_file: &ClassFile<'_>,
    method: &Method,
    context: &C,
    config: &VerifierConfig,
) -> Result<VerificationResult>
Expand description

Verifies a method’s bytecode.

This is the main entry point for bytecode verification. It automatically selects the appropriate verification strategy based on class file version and configuration.

§Arguments

  • class_file - The class file containing the method
  • method - The method to verify
  • context - The verification context for type hierarchy checks
  • config - Verifier configuration

§Returns

A VerificationResult with details about the verification.

§Errors

Returns an error if verification fails and fallback is not possible.