Skip to content

Commit

Permalink
Merge pull request #136 from greg0ire/1.5.x
Browse files Browse the repository at this point in the history
Merge 1.4.x up into 1.5.x
  • Loading branch information
greg0ire authored Aug 5, 2024
2 parents b426bc5 + db8be83 commit 40ee470
Show file tree
Hide file tree
Showing 7 changed files with 25 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/Tokenizer.php
Original file line number Diff line number Diff line change
Expand Up @@ -412,6 +412,7 @@ final class Tokenizer
'OUTER JOIN',
'RIGHT JOIN',
'RIGHT OUTER JOIN',
'STRAIGHT_JOIN',
'XOR',
];

Expand Down
6 changes: 6 additions & 0 deletions tests/clihighlight.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1179,3 +1179,9 @@ MY_NON_TOP_LEVEL_KEYWORD_FX_3();
DBMS_OUTPUT.PUT_LINE(i);
END LOOP;
END;
---
SELECT
a
FROM
test
STRAIGHT_JOIN test2 ON test.id = test2.id
2 changes: 2 additions & 0 deletions tests/compress.txt
Original file line number Diff line number Diff line change
Expand Up @@ -105,3 +105,5 @@ SELECT ( SELECT * FROM T LIMIT 5 OFFSET 10 ) PostgreSQL_offset_10_limit_5, ( SEL
begin try insert into [t] ([name], [int], [float], [null]) values (N'Ewa', 1, 1.0, null); end try begin catch if ERROR_NUMBER() = 544 begin set IDENTITY_INSERT [t] on; begin try insert into [t] ([name], [int], [float], [null]) values (N'Ewa', 1, 1.0, null); set IDENTITY_INSERT [t] off; end try begin catch set IDENTITY_INSERT [t] off; throw; end catch end else begin throw; end end catch
---
BEGIN FOR i IN 1..5 LOOP DBMS_OUTPUT.PUT_LINE(i); END LOOP; END;
---
SELECT a FROM test STRAIGHT_JOIN test2 ON test.id = test2.id
6 changes: 6 additions & 0 deletions tests/format-highlight.html
Original file line number Diff line number Diff line change
Expand Up @@ -1179,3 +1179,9 @@
<span style="color: #333;">DBMS_OUTPUT</span><span >.</span><span style="color: #333;">PUT_LINE</span>(<span style="color: #333;">i</span>)<span >;</span>
<span style="font-weight:bold;">END</span> <span style="color: #333;">LOOP</span><span >;</span>
<span style="font-weight:bold;">END</span><span >;</span></pre>
---
<pre style="color: black; background-color: white;"><span style="font-weight:bold;">SELECT</span>
<span style="color: #333;">a</span>
<span style="font-weight:bold;">FROM</span>
<span style="color: #333;">test</span>
<span style="font-weight:bold;">STRAIGHT_JOIN</span> <span style="color: #333;">test2</span> <span style="font-weight:bold;">ON</span> <span style="color: #333;">test</span><span >.</span><span style="color: #333;">id</span> <span >=</span> <span style="color: #333;">test2</span><span >.</span><span style="color: #333;">id</span></pre>
6 changes: 6 additions & 0 deletions tests/format.txt
Original file line number Diff line number Diff line change
Expand Up @@ -1177,3 +1177,9 @@ BEGIN
DBMS_OUTPUT.PUT_LINE(i);
END LOOP;
END;
---
SELECT
a
FROM
test
STRAIGHT_JOIN test2 ON test.id = test2.id
3 changes: 2 additions & 1 deletion tests/highlight.html
Original file line number Diff line number Diff line change
Expand Up @@ -407,4 +407,5 @@
<span style="color: #333;">DBMS_OUTPUT</span><span >.</span><span style="color: #333;">PUT_LINE</span>(<span style="color: #333;">i</span>)<span >;</span>
<span style="font-weight:bold;">END</span> <span style="color: #333;">LOOP</span><span >;</span>
<span style="font-weight:bold;">END</span><span >;</span></pre>

---
<pre style="color: black; background-color: white;"><span style="font-weight:bold;">SELECT</span> <span style="color: #333;">a</span> <span style="font-weight:bold;">FROM</span> <span style="color: #333;">test</span> <span style="font-weight:bold;">STRAIGHT_JOIN</span> <span style="color: #333;">test2</span> <span style="font-weight:bold;">ON</span> <span style="color: #333;">test</span><span >.</span><span style="color: #333;">id</span> <span >=</span> <span style="color: #333;">test2</span><span >.</span><span style="color: #333;">id</span></pre>
2 changes: 2 additions & 0 deletions tests/sql.sql
Original file line number Diff line number Diff line change
Expand Up @@ -407,3 +407,5 @@ BEGIN
DBMS_OUTPUT.PUT_LINE(i);
END LOOP;
END;
---
SELECT a FROM test STRAIGHT_JOIN test2 ON test.id = test2.id

0 comments on commit 40ee470

Please sign in to comment.