Skip to main content

Module lang_items

Module lang_items 

Source
Expand description

Detecting lang items.

Language items are items that represent concepts intrinsic to the language itself. Examples are:

  • Traits that specify β€œkinds”; e.g., Sync, Send.
  • Traits that represent operators; e.g., Add, Sub, Index.
  • Functions called by the compiler itself.

Re-exportsΒ§

use rustc_attr_ir::lang_items::LangItem; πŸ”’
use rustc_hir::def_id::DefId; πŸ”’
use rustc_span::Span; πŸ”’
use rustc_target::spec::PanicStrategy; πŸ”’
use crate::ty; πŸ”’
use crate::ty::TyCtxt; πŸ”’

FunctionsΒ§

required
Returns true if the specified lang_item must be present for this compilation.