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

pretty printing doesn't put enough EOLs #545

Closed
yegor256 opened this issue Nov 23, 2024 · 6 comments · Fixed by #550
Closed

pretty printing doesn't put enough EOLs #545

yegor256 opened this issue Nov 23, 2024 · 6 comments · Fixed by #550

Comments

@yegor256
Copy link
Member

related to #515

I'm getting this output:

...
method-params ↦ Φ.jeo.params, annotations ↦ Φ.org.eolang.seq0, φ ↦ Φ.org.eolang.seq3 (
  α0 ↦ ξ.aload-BD64, α1 ↦ ξ.invokespecial-BD66, α2 ↦ ξ.return-BD68
),
trycatchblocks-object@init@ ↦ Φ.org.eolang.seq0, local-variable-table ↦ Φ.org.eolang.seq0, aload-BD64 ↦ Φ.jeo.opcode (
  α0 ↦ Φ.jeo.int (
    α0 ↦ Φ.org.eolang.bytes (
      Δ ⤍ 00-00-00-00-00-00-00-19
    )
  ),
  α1 ↦ Φ.jeo.int (
    α0 ↦ Φ.org.eolang.bytes (
      Δ ⤍ 00-00-00-00-00-00-00-00
    )
  )
),
...

Obviously, a better formatting would be:

...
method-params ↦ Φ.jeo.params, 
annotations ↦ Φ.org.eolang.seq0, 
φ ↦ Φ.org.eolang.seq3 (
  α0 ↦ ξ.aload-BD64, 
  α1 ↦ ξ.invokespecial-BD66, 
  α2 ↦ ξ.return-BD68
),
trycatchblocks-object@init@ ↦ Φ.org.eolang.seq0, 
local-variable-table ↦ Φ.org.eolang.seq0, 
aload-BD64 ↦ Φ.jeo.opcode (
  α0 ↦ Φ.jeo.int (
    α0 ↦ Φ.org.eolang.bytes (
      Δ ⤍ 00-00-00-00-00-00-00-19
    )
  ),
  α1 ↦ Φ.jeo.int (
    α0 ↦ Φ.org.eolang.bytes (
      Δ ⤍ 00-00-00-00-00-00-00-00
    )
  )
),
@yegor256
Copy link
Member Author

@deemp @fizruk please, check

@yegor256
Copy link
Member Author

@fizruk here is a more simple example:

$ cat bar.phi
{⟦ m ↦ ⟦ x ↦ ξ.t, φ ↦ ⟦ t ↦ ⟦⟧ ⟧ ⟧.x ⟧}
$ eo-phi-normalizer rewrite -s bar.phi
{
  ⟦
    m ↦ ⟦
      ρ ↦ ⟦
        t ↦ ⟦ ⟧, ρ ↦ ⟦
          x ↦ ξ.t, φ ↦ ⟦
            t ↦ ⟦ ⟧
          ⟧
        ⟧
      ⟧
    ⟧
  ⟧
}

Obviously, the formatting is wrong.

@yegor256
Copy link
Member Author

@deemp let's close it when the problem is solved on my side, in a new release

@yegor256 yegor256 reopened this Nov 26, 2024
@deemp
Copy link
Member

deemp commented Nov 26, 2024

@yegor256, we've released v2.2.0 that should resolve this issue. Please check

@0crat
Copy link

0crat commented Nov 27, 2024

@yegor256 Thank you for your submission! Unfortunately, it wasn't accepted by the team. As per our policy, this results in a -16 point penalty. Your current balance is now -78. Don't be discouraged, though! Your efforts to improve our project's quality are valuable. Keep reporting bugs and suggesting enhancements, but try to be more thorough next time. Remember, bugs are welcome when they help us grow!

@yegor256
Copy link
Member Author

@deemp this problem is gone

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants