Skip to content

Commit cabd43d

Browse files
authored
fix(angelscript) Fix highlighting of int8, int16, int32, int64 (#3464)
* Swap order of int/uint and their explicit type variations to fix incomplete highlighting
1 parent 112135f commit cabd43d

File tree

5 files changed

+6
-2
lines changed

5 files changed

+6
-2
lines changed

CHANGES.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,10 @@ Grammars:
44

55
- enh(php) named arguments [Wojciech Kania][]
66
- fix(php) PHP constants [Wojciech Kania][]
7+
- fix(angelscript) incomplete int8, int16, int32, int64 highlighting [Melissa Geels][]
78

89
[Wojciech Kania]: https://github.com/wkania
10+
[Melissa Geels]: https://github.com/codecat
911

1012
## Version 11.4.0
1113

src/languages/angelscript.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ Website: https://www.angelcode.com/angelscript/
99
export default function(hljs) {
1010
const builtInTypeMode = {
1111
className: 'built_in',
12-
begin: '\\b(void|bool|int|int8|int16|int32|int64|uint|uint8|uint16|uint32|uint64|string|ref|array|double|float|auto|dictionary)'
12+
begin: '\\b(void|bool|int8|int16|int32|int64|int|uint8|uint16|uint32|uint64|uint|string|ref|array|double|float|auto|dictionary)'
1313
};
1414

1515
const objectHandleMode = {

test/detect/angelscript/default.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ namespace MyApplication
1515
array<SomeClass@> m_children;
1616
array<array<SomeClass@>> m_subChildren; // Nested templates
1717

18-
int m_thing;
18+
uint64 m_thing;
1919

2020
SomeClass()
2121
{

test/markup/angelscript/default.expect.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
<span class="hljs-built_in">array<span class="hljs-keyword">&lt;<span class="hljs-built_in">array<span class="hljs-keyword">&lt;<span class="hljs-symbol">SomeClass@</span>&gt;</span></span>&gt;</span></span> m_subChildren; <span class="hljs-comment">// Nested templates</span>
1717

1818
<span class="hljs-built_in">int</span> m_thing;
19+
<span class="hljs-built_in">uint64</span> m_thing2;
1920

2021
SomeClass()
2122
{

test/markup/angelscript/default.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ namespace MyApplication
1616
array<array<SomeClass@>> m_subChildren; // Nested templates
1717

1818
int m_thing;
19+
uint64 m_thing2;
1920

2021
SomeClass()
2122
{

0 commit comments

Comments
 (0)