lib/rouge/lexers/gdscript.rb in rouge-4.2.0 vs lib/rouge/lexers/gdscript.rb in rouge-4.2.1
- old
+ new
@@ -10,27 +10,27 @@
aliases 'gd', 'gdscript'
filenames '*.gd'
mimetypes 'text/x-gdscript', 'application/x-gdscript'
def self.keywords
- @keywords = %w(
+ @keywords ||= %w(
and in not or as breakpoint class class_name extends is func setget
signal tool const enum export onready static var break continue
if elif else for pass return match while remote master puppet
remotesync mastersync puppetsync
).join('|')
end
# Reserved for future implementation
def self.keywords_reserved
- @keywords_reserved = %w(
+ @keywords_reserved ||= %w(
do switch case
).join('|')
end
def self.builtins
- builtins = %w(
+ @builtins ||= %w(
Color8 ColorN abs acos asin assert atan atan2 bytes2var ceil char
clamp convert cos cosh db2linear decimals dectime deg2rad dict2inst
ease exp floor fmod fposmod funcref hash inst2dict instance_from_id
is_inf is_nan lerp linear2db load log max min nearest_po2 pow
preload print print_stack printerr printraw prints printt rad2deg
@@ -39,10 +39,10 @@
var2bytes var2str weakref yield
).join('|')
end
def self.builtins_type
- @builtins_type = %w(
+ @builtins_type ||= %w(
bool int float String Vector2 Rect2 Transform2D Vector3 AABB
Plane Quat Basis Transform Color RID Object NodePath Dictionary
Array PoolByteArray PoolIntArray PoolRealArray PoolStringArray
PoolVector2Array PoolVector3Array PoolColorArray null
).join('|')