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

Stylistic set for Go #59

Closed
bebraw opened this issue Feb 5, 2021 · 6 comments
Closed

Stylistic set for Go #59

bebraw opened this issue Feb 5, 2021 · 6 comments

Comments

@bebraw
Copy link
Contributor

bebraw commented Feb 5, 2021

My understanding is that Go is well supported by ligatures already. Here's a complete set of characters to validate: https://golang.org/ref/spec#Operators_and_punctuation .

+    &     +=    &=     &&    ==    !=    (    )
-    |     -=    |=     ||    <     <=    [    ]
*    ^     *=    ^=     <-    >     >=    {    }
/    <<    /=    <<=    ++    =     :=    ,    ;
%    >>    %=    >>=    --    !     ...   .    :
     &^          &^=
@flowchartsman
Copy link

Heavy Go user here, would love to see some of these before taking the plunge.

@MarcusSterz
Copy link

Wondering if the second ligature is an option or too confusing? Otherwise %= would be only a white space ligature.
Bildschirmfoto 2023-11-16 um 13 39 44

@bebraw
Copy link
Contributor Author

bebraw commented Nov 16, 2023

Whitespace alignment might be safer.

@okonet
Copy link

okonet commented Nov 16, 2023

Yeah, the ligature looks weird.

@bebraw
Copy link
Contributor Author

bebraw commented Nov 17, 2023

There's a prerelease containing Go specific ligatures available now. These might have to go behind a specific stylistic set in case they are too specific for other languages.

@bebraw
Copy link
Contributor Author

bebraw commented Dec 15, 2023

Included in 2.012. The exact ligatures added are +=, -=, *=, %=, &=, &^, and &^=.

@bebraw bebraw closed this as completed Dec 15, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants