Fix GDScript code style regarding colon

This commit is contained in:
Danil Alexeev 2023-03-03 17:42:32 +03:00
parent 61d2c85511
commit ea5fd3d732
No known key found for this signature in database
GPG key ID: 124453E157DA8DC7
28 changed files with 74 additions and 72 deletions

View file

@ -1,7 +1,7 @@
enum MyEnum { ENUM_VALUE_1, ENUM_VALUE_2 }
enum MyOtherEnum { OTHER_ENUM_VALUE_1, OTHER_ENUM_VALUE_2 }
func enum_func(e : MyEnum) -> void:
func enum_func(e: MyEnum) -> void:
print(e)
func test():

View file

@ -4,4 +4,4 @@ func test():
x.free()
var ok = x
var bad : Node = x
var bad: Node = x

View file

@ -2,5 +2,5 @@ enum LocalNamed { VALUE_A, VALUE_B, VALUE_C = 42 }
func test():
const P = preload("../features/enum_from_outer.gd")
var x : LocalNamed
var x: LocalNamed
x = P.Named.VALUE_A

View file

@ -1,7 +1,7 @@
var _prop : int
var _prop: int
# Getter function has wrong return type.
var prop : String:
var prop: String:
get = get_prop
func get_prop():

View file

@ -1,10 +1,10 @@
var _prop : int
var _prop: int
# Setter function has wrong argument type.
var prop : String:
var prop: String:
set = set_prop
func set_prop(value : int):
func set_prop(value: int):
_prop = value
func test():

View file

@ -1,7 +1,7 @@
var _prop : int
var _prop: int
# Inline getter returns int instead of String.
var prop : String:
var prop: String:
get:
return _prop

View file

@ -1,7 +1,7 @@
var _prop : int
var _prop: int
# Inline setter assigns String to int.
var prop : String:
var prop: String:
set(value):
_prop = value

View file

@ -7,4 +7,4 @@ func test():
x.free()
var ok = x
var bad : A = x
var bad: A = x