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

Make bat::PrettyPrinter::syntaxes() iterate over new bat::Syntax struct #2222

Merged
merged 1 commit into from
Sep 3, 2022

Commits on Sep 3, 2022

  1. Make bat::PrettyPrinter::syntaxes() iterate over new bat::Syntax

    …struct
    
    We can't keep `syntect::parsing::SyntaxReference` as part of the public
    API, because that might prevent us from bumping to syntect 6.0.0 without
    also bumping bat to v2.0.0, once we reach v1.0.0.
    
    So introduce a new stripped down struct `Syntax` and return that
    instead. Let it be fully owned to make the API simple. It is not going
    to be in a hot code path anyway.
    
    I have looked at all code of our 27 dependents but I can't find a single
    instance of this method being used, so this change should be safe for
    v1.0.0.
    Enselic committed Sep 3, 2022
    Configuration menu
    Copy the full SHA
    c7cea17 View commit details
    Browse the repository at this point in the history