Skip to content

Feature: structural diffs (diff ASTs rather than text) #780

@OliverJAsh

Description

@OliverJAsh

Prerequisites

Proposal

I'm a big fan of structural highlighting as seen in tools like difftastic and Linear Diffs. I would like to propose bringing this feature to Pierre Diffs.

Motivation and context

Formatting changes add a lot of noise to diffs. This can be partially mitigated by configuring the diff to ignore whitespace (e.g. git diff -w) or perform a word diff (e.g. git diff --word-diff), but we can achieve even better results with a "structural diff" that performs a diff on ASTs rather than text. See https://difftastic.wilfred.me.uk/introduction.html#syntactic-diffing.

Personally, after using difftastic for a few months, I really struggle to go back. There's a huge difference in diff readability.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions