package grace

  1. Overview
  2. Docs
A fancy diagnostics library that allows your compilers to exit with grace

Install

dune-project
 Dependency

Authors

Maintainers

Sources

grace-0.4.1.tbz
sha256=d49754224206de44855590848b3a5a6cc1d5c46cf99a4e5810ca3041d436a28e
sha512=2984b5a6284bf8bbd05419cf850c15c34bc19c19f0c8928b83cc1be1c0bfc84aafef6d992e7435c2f48ba361a6f3aab679abd02f0e6472361c8cec7d497bc405

doc/grace.source_reader/Grace_source_reader/Line_starts/index.html

Module Grace_source_reader.Line_startsSource

Sourcetype t = {
  1. unsafe_get : int -> Grace.Byte_index.t;
  2. length : int;
}

The type of line starts.

For computation of line numbers from ranges, we require a function mapping line indices to byte indicies and the maximum line index.

A valid line_starts for a source satisfies:

  1. ...
Sourcetype fn = Source_descr.t -> t

A line starts function maps a given source (descriptor) to its line starts.

Sourceval default_fn : fn