Skip to content

Error from Snippet to DisplayList #26

Closed

Description

@zzau13

I use this in yarte here.

With any error returns something similar to this:

DisplayList { body: [Raw(Annotation { annotation: Annotation { annotation_type: Error, id: None, label: [DisplayTextFragment { content: "", style: Emphasis }] }, source_aligned: false, continuation: false }), Raw(Origin { path: "templates/deep/more/card/hi.hbs", pos: Some((7, 21)), header_type: Initial }), Source { lineno: None, inline_marks: [], line: Empty }, Source { lineno: Some(7), inline_marks: [], line: Content { text: "<h1>Hi, {{ name }} {{ @lastname }}", range: (0, 35) } }, Source { lineno: None, inline_marks: [], 

// Label is empty
line: Annotation { 
    annotation: Annotation { 
       annotation_type: None, id: None, 
       label: [/* WHY IS EMPTY */] }, 

range: (21, 22), annotation_type: Error, annotation_part: MultilineStart } }, Source { lineno: None, inline_marks: [], line: Empty }] }

And as you can see the label has vanished

Activity

  1. zbraniecki commented on Mar 10, 2020

    @zbraniecki
    Contributor

    Thank you for the report! I'm a bit swamped lately but will try to find time to debug it! PRs welcomed!

  2. zzau13 commented on Mar 10, 2020

    @zzau13
    ContributorAuthor

    I'm already in it.

  3. added a commit that references this issue on Dec 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions