Skip to main content

RubyGemSurface

Trait RubyGemSurface 

Source
pub trait RubyGemSurface {
    // Required methods
    fn constant_boundary(
        &self,
        owner_path: &[String],
        terminal: &str,
    ) -> RubyGemBoundary;
    fn require_boundary(&self, require_path: &str) -> RubyGemBoundary;
}
Expand description

The retained gem surface a Ruby diagnostic request may read.

Every method answers only from state a host already published. An implementation must never run Bundler, read a gem archive, walk a gem directory, or start dependency discovery: a missing answer is RubyGemBoundary::Unpublished or RubyGemBoundary::Incomplete, never a blocking call.

Required Methods§

Source

fn constant_boundary( &self, owner_path: &[String], terminal: &str, ) -> RubyGemBoundary

Classify terminal under the constant path owner_path, which is the AST-derived segment list of the reference’s scope (["Widget"] for Widget::Config) and is never empty.

Source

fn require_boundary(&self, require_path: &str) -> RubyGemBoundary

Classify the gem that a require argument loads. Never Absent: a load path that no pack covers is a boundary this pass cannot see past, not a missing file.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§