astrale-sharp / typstfmt

Apache License 2.0
253 stars 26 forks source link

Multi Line Comments Drifting Right #138

Open BattleCh1cken opened 8 months ago

BattleCh1cken commented 8 months ago

Tested on commit 792f08f41d3c081bcc04675100e8a5f615567b3a

Describe the bug

Formatting a multi line comment that is inside parenthesis makes it move to the right, even if the document has not been changed since the last format.

To Reproduce Steps to reproduce the behavior:

  1. Start with this code:

    #let test_func() = {
    (
    /*
    test
    */
    )
  2. Repeatedly format

  3. Watch as the comment goes on a journey to the right side of your screen

    #let test_func() = {
    (/*
              test
              */)
    }
BattleCh1cken commented 8 months ago

This may be related to #136 but I'm unsure.

astrale-sharp commented 8 months ago

The comments too??? :sob:

thanks for the report !!