Module papyri_lang::errors

source ·
Expand description

This module contains type definitions for errors and warnings which can occur during compilation of a Papyri source file.

Structs

  • Represents that a failure occurred but a diagnostic was already reported for it.
  • Represents a span of code in a source file, while also holding a reference to the source file itself.

Enums

  • Represents an error which occurs when loading a module.
  • Represents an error which occurs at runtime due to an undefined or invalid name; there is an associated stack trace.
  • Represents an error or warning which occurs while attempting to compile a Papyri source file.
  • Controls which severity of diagnostics are reported by the Papyri compiler.
  • Represents an error which occurs at runtime; there is an associated stack trace.
  • Represents a syntax error in a Papyri source file.
  • Represents a type error which occurs during compilation of a Papyri source file.
  • Represents a warning which occurs during compilation of a Papyri source file.

Functions

  • Reports an internal compiler error, indicating a bug or mistake in the Papyri compiler. Use ice_at instead if the error corresponds with some code in a Papyri source file.
  • Reports an internal compiler error, indicating a bug or mistake in the Papyri compiler. Use ice instead if the error does not correspond with any particular code in a Papyri source file.

Type Definitions

  • A diagnostic sink for PapyriErrors. It has convenience methods for reporting each kind of error or warning.
  • A result type for which Err means a diagnostic must be reported by the caller.
  • A result type for which Err means a diagnostic has already been reported by the callee.
  • Represents a stack trace, which is associated with a diagnostic.