George Marques
81c7cae567
GDScript: Don't get invalid dictionary key during completion
...
We try to get the value out of a dictionary in order to establish its
type for completion purposes. However, if the dictionary or the key
is not a constant, we cannot safely get the actual value, so we skip
this and just try to infer from static typing.
Getting the value directly with `Variant::get()` generate errors if the
base is a Dictionary and the key is of an invalid type. So before trying
to get it we use the Dictionary validator to make sure it we can safely
try to get the key.
2025-07-24 15:02:40 -03:00
Thaddeus Crews
25dcf7d2a0
Merge pull request #108306 from Chaosus/gds_fix_super_completion
...
Fix lookup symbol for `super()`
2025-07-17 10:34:48 -05:00
Thaddeus Crews
c977b597b8
Merge pull request #107872 from Thought-Weaver/users/loganapple/editor-caret-fix
...
[Autocomplete] Avoid prepending literals when the character has already been typed
2025-07-10 11:39:30 -05:00
Chaosus
c232b7c717
Fix lookup symbol for super()
2025-07-08 16:21:39 +03:00
HolonProduction
d4abc211f1
GDScript: Fix autocompletion issues with nested types
2025-07-08 14:48:21 +02:00
Logan Apple
216c462277
Initial fix for double caret inserting in NodePath
...
Additional cases where prepending doubles up
Moved code to helper function
Added unit tests
Lookup caret character instead of passing position
Switched to using the parsed type
Adding safety checks and various cleanup
2025-07-07 09:23:32 -07:00
Thaddeus Crews
77b680244d
Merge pull request #102186 from HolonProduction/completion-builtin-enum
...
Improve GDScript editor support for global enums
2025-07-03 12:21:19 -05:00
Thaddeus Crews
bad29ef0c7
Merge pull request #107636 from HolonProduction/completion-dont-use-next
...
Autocompletion: Don't use `next` for `GET_NODE` inference
2025-07-01 17:57:59 -05:00
Thaddeus Crews
ee5859b7ae
Merge pull request #92584 from HolonProduction/autocompletion-assign-variant
...
Autocompletion: Fix type resolution when assigning variant
2025-07-01 17:57:51 -05:00
Rémi Verschelde
ebc36a7225
Merge pull request #107717 from aaronfranke/abstract-annotation
...
GDScript: Replace `abstract` keyword with `@abstract` annotation
2025-06-27 17:12:56 +02:00
Thaddeus Crews
4a90220fc9
Merge pull request #107852 from HolonProduction/completion-filter-current-impl
...
Autocompletion: Don't filter overrides when the existing function is the current one
2025-06-27 09:39:52 -05:00
Thaddeus Crews
7ea1b3aabb
Merge pull request #105801 from dalexeev/gds-update-stack-funcs
...
GDScript: Update `get_stack()`, `print_stack()`, and `print_debug()`
2025-06-24 09:58:47 -05:00
Aaron Franke
1085200f51
GDScript: Replace abstract keyword with @abstract annotation
...
Co-authored-by: Danil Alexeev <dalexeev12@yandex.ru>
2025-06-23 12:24:45 -07:00
HolonProduction
991c1a85a9
Autocompletion: Don't filter overrides when the existing function is the current one
2025-06-22 16:25:36 +02:00
HolonProduction
49e8d3ff98
Autocompletion: Don't use next for GET_NODE inference
2025-06-17 17:03:59 +02:00
HolonProduction
242b5efd9d
Autocompletion: Fix type resolution when assigning variant
2025-06-15 20:17:19 +02:00
HolonProduction
af54b13603
Autocompletion: Add support for global enums
2025-06-15 19:41:13 +02:00
Rémi Verschelde
ea908f1ab2
Merge pull request #107416 from dalexeev/gds-fix-for-range-assignment
...
GDScript: Add missing type conversions in `for range`
2025-06-12 22:49:08 +02:00
Rémi Verschelde
f400e10011
Merge pull request #107315 from HolonProduction/lsp-brief-fix
...
LSP: Fix class documentation to include brief
2025-06-12 11:56:42 +02:00
Danil Alexeev
e2d4469dc2
GDScript: Add missing type conversions in for range
2025-06-11 20:45:47 +03:00
Thaddeus Crews
0f05e91889
Merge pull request #82808 from dalexeev/gds-vararg
...
GDScript: Add support for variadic functions
2025-06-09 17:08:48 -05:00
Danil Alexeev
a13fbc6e3e
GDScript: Optimize non-constant for-range
2025-06-09 22:04:39 +03:00
Danil Alexeev
ee121ef80e
GDScript: Add support for variadic functions
2025-06-09 21:53:05 +03:00
Thaddeus Crews
86415f1732
Merge pull request #99150 from dalexeev/gds-fix-callable-call-errror-text
...
GDScript: Fix `Callable` call error text
2025-06-09 12:31:39 -05:00
Danil Alexeev
a7cf2069d5
GDScript: Add abstract methods
...
Co-authored-by: ryanabx <ryanbrue@hotmail.com>
2025-06-09 20:11:58 +03:00
HolonProduction
30672ffce7
LSP: Fix class documentation to include brief
2025-06-09 12:24:35 +02:00
Rémi Verschelde
fb59a99244
Merge pull request #106198 from SatLess/User-Func-Autocomplete
...
Add code completion for user-defined methods when overriding in GDScript
2025-06-09 00:44:22 +02:00
Sat
fc4df4b17d
Added working version for user-defined function autocompletion
2025-06-08 07:01:35 -03:00
Thaddeus Crews
eef13d5ae7
Merge pull request #105347 from HolonProduction/lsp-utf8
...
LSP: Account for unicode identifiers
2025-05-28 09:47:29 -05:00
Thaddeus Crews
63dff62948
Merge pull request #100673 from RandomShaper/res_duplicate
...
Overhaul resource duplication
2025-05-27 09:39:25 -05:00
Pedro J. Estébanez
6841b45552
Add tests for resource duplication
2025-05-26 17:05:04 +02:00
Thaddeus Crews
ee82adcf04
Merge pull request #105413 from HolonProduction/gdscript-recover-match
...
GDScript: Do phrase level recovery for match
2025-05-23 09:46:10 -05:00
Thaddeus Crews
1c4b660312
Merge pull request #96611 from Dynamic-Pistol/master
...
Add `PROPERTY_HINT_INPUT_NAME` for use with `@export_custom` to allow using input actions
2025-05-13 16:22:25 -05:00
Thaddeus Crews
b59d6bea4f
Merge pull request #67777 from aaronfranke/virtually-annotated
...
Add a keyword for abstract classes in GDScript
2025-05-13 16:22:16 -05:00
Malcolm Anderson
d8db03e31a
Fix a few GDScript warning messages for grammar and consistency
...
Regenerate test results
Improve warning message for `INT_AS_ENUM_WITHOUT_CAST`
Improve `REDUNDANT_AWAIT` message and regenerate tests
Allow warning message for UNASSIGNED_VARIABLE_OP_ASSIGN to display specific operator
Remove "being" from some messages to make them consistent and clearer
Update expected test results
Use Variant::get_operator_name for determining string representation of operator instead of big switch-case
Update tests
Update modules/gdscript/gdscript_warning.cpp
Co-authored-by: Danil Alexeev <dalexeev12@yandex.ru>
Update tests... again
2025-05-06 20:28:01 -07:00
Danil Alexeev
2b30f23595
GDScript: Fix Callable call error text
2025-05-02 18:30:35 +03:00
Aaron Franke
067704f1cd
Add a keyword for abstract classes in GDScript
...
Co-authored-by: Danil Alexeev <danil@alexeev.xyz>
2025-05-02 00:03:04 -07:00
Thaddeus Crews
83d98f02e3
Merge pull request #105415 from HolonProduction/hardcoded-braces
...
Autocompletion: Remove additional parenthesis from utility function options
2025-04-29 11:24:06 -05:00
Danil Alexeev
2bacfc8b59
GDScript: Update get_stack(), print_stack(), and print_debug()
2025-04-26 21:10:41 +03:00
Malcolm Anderson
5c662f7707
Add errors for keywords removed in Godot 4
...
Update modules/gdscript/gdscript_parser.cpp
Co-authored-by: Danil Alexeev <dalexeev12@yandex.ru>
Improve error message
Add tests
Add errors for other removed keywords
Remove very old keywords and improve wording of errors
2025-04-24 22:32:34 -07:00
Thaddeus Crews
5d697c31c1
Merge pull request #78837 from dalexeev/gds-const-array-and-dict-constructors
...
GDScript: Add constant `Array` and `Dictionary` constructors
2025-04-24 09:09:29 -05:00
Dynamic-Pistol
c8fed1e1d0
Add PROPERTY_HINT_INPUT_NAME
...
Added PROPERTY_HINT_INPUT_NAME for StringName based off https://github.com/godotengine/godot-proposals/discussions/7559
2025-04-23 22:23:44 +02:00
HolonProduction
3f0ff0417c
Autocompletion: Remove additional brace from utility function options
2025-04-15 13:25:28 +02:00
HolonProduction
4a0e40f6ea
GDScript: Do phrase level recovery for match
2025-04-15 13:00:43 +02:00
HolonProduction
e213737d66
LSP: Account for unicode identifiers
2025-04-15 09:51:50 +02:00
Thaddeus Crews
bef5d1e4f8
Merge pull request #102218 from HolonProduction/dictionary-recovery
...
GDScript: Do phrase level recovery when parsing faulty dictionaries
2025-04-14 19:39:50 -05:00
Thaddeus Crews
9e158215d1
Merge pull request #96375 from HolonProduction/completion-callable-braces
...
Autocompletion: Don't add parenthesis if `Callable` is expected
2025-04-10 16:53:45 -05:00
Nolkaloid
c1cdaf7b16
Add gdscript tests for callv with const arrays
2025-04-10 23:13:01 +02:00
HolonProduction
e7487263ad
Autocompletion: Don't add parenthesis if Callable is expected
2025-04-10 18:40:32 +02:00
Thaddeus Crews
4248411baf
Merge pull request #102521 from HolonProduction/cancel-await
...
GDScript: Cancel suspended functions when reloading a script
2025-04-08 12:32:52 -05:00