Sublime Forum

Wrong ligature for NULL-safe equal to operator in SQL syntax

#1

As in the title, typing <=> results in this:

which is strange as Find Results for this piece of code renders the symbol correctly:

I think it’s because no syntax definitions are applied to search result. Does this mean that SQL syntax is at fault here?
PHP syntax also renders the symbol as it should.

0 Likes

#2

Most likely, the SQL syntax is recognizing <= followed by >, and it isn’t written to specifically recognize <=>.

3 Likes

#3

OK, I did edit the following code from SQL.sublime-syntax:

    scope: keyword.operator.star.sql
    - match: "[!<>]?=|<>|<|>"

to:

   scope: keyword.operator.star.sql
    - match: "<=>|[!<>]?=|<>|<|>"

and it works now, but I have no idea if it is a valid place.

2 Likes

#4

If you send a pull request to https://github.com/sublimehq/Packages/pulls, the contributors can do a review and give feedback about testing and if it is the proper place to edit the syntax.

5 Likes