Skip to content

See if truncate_source can be removed #1846

@mre

Description

@mre

In #1832, we moved to Cow for InputSource::String.

We should consider removing this method or alternatively updating the TODO:

/// Truncate the source in case it gets too long
///
/// This is only needed for string inputs.
/// For other inputs, the source is simply a "label" (an enum variant).
// TODO: This would not be necessary if we used `Cow` for the source.
fn truncate_source(source: &InputSource) -> InputSource {

Originally posted by @katrinafyi in #1832 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions