Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix some typos in the docs #125

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -234,7 +234,7 @@ pub enum ReportKind<'a> {
/// The report is a warning and indicates a likely problem, but not to the extent that the requested action cannot
/// be performed.
Warning,
/// The report is advice to the user about a potential anti-pattern of other benign issues.
/// The report is advice to the user about a potential anti-pattern or other benign issues.
Advice,
/// The report is of a kind not built into Ariadne.
Custom(&'a str, Color),
Expand Down Expand Up @@ -386,9 +386,9 @@ pub enum CharSet {
/// Possible character sets to use when rendering diagnostics.
#[derive(Copy, Clone, Debug, PartialEq, Eq)]
pub enum IndexType {
/// Byte spans. Always results in O(1) loopups
/// Byte spans. Always results in O(1) lookups.
Byte,
/// Char based spans. May incur O(n) lookups
/// Char based spans. May incur O(n) lookups.
Char,
}

Expand All @@ -411,7 +411,7 @@ impl Config {
///
/// The alternative to this is to insert crossing characters. However, these interact poorly with label colours.
///
/// If unspecified, this defaults to [`false`].
/// If unspecified, this defaults to [`true`].
pub const fn with_cross_gap(mut self, cross_gap: bool) -> Self {
self.cross_gap = cross_gap;
self
Expand Down Expand Up @@ -467,7 +467,7 @@ impl Config {
}
/// Should this report use byte spans instead of char spans?
///
/// If unspecified, this defaults to 'false'
/// If unspecified, this defaults to [`IndexType::Char`].
pub const fn with_index_type(mut self, index_type: IndexType) -> Self {
self.index_type = index_type;
self
Expand Down