316f78a037
Add default argument bindings to GDScript annotations
2022-07-11 23:02:55 +03:00
12b9572121
Parser: Properly set node extents
2022-07-11 21:31:15 +03:00
5a906a33d9
Prevent unnecessary additional parser error
2022-07-11 03:32:28 +03:00
4f36b2df2a
Fix parser stuck in an error loop
2022-07-11 02:42:40 +03:00
f0eb3ac5d3
Merge pull request #62701 from cdemirer/for-variable-conflict
2022-07-06 16:02:49 +02:00
635d447a69
Merge pull request #62713 from YuriSizov/docs-scripting-annotations
2022-07-06 15:31:19 +02:00
f85bafaa11
Add grouping annotations for class properties in GDScript
2022-07-05 22:01:40 +03:00
a9098e6147
Add support for documenting built-in annotations
2022-07-04 20:21:39 +03:00
dbdf0174b4
Do error when for variable conflicts with a variable in scope
2022-07-04 12:30:39 +03:00
92367bad4e
Fix GDScript parser sometimes crashing when issuing warning for unreachable pattern
2022-07-01 02:05:00 +02:00
9490146a16
GDScript: Enable exporting nodes to the inspector
...
Also fix an small issue in the property editor for NodePath trying to
use the meta property when not needed.
2022-06-27 18:42:52 -03:00
dd8c0522a6
Implement varargs in Methodinfo
...
Variadic templates are an awful thing. Implements #62233 using them in MethodInfo so less changes are required.
2022-06-23 14:50:38 +02:00
46bbbd9770
Allow autocompletion of "noslider" in export_range
2022-06-19 17:11:49 +02:00
68bf4eb100
Merge pull request #61440 from vnen/gdscript-scene-unique-nodes
...
GDScript: Support `%` in shorthand for `get_node`
2022-05-31 12:36:37 +02:00
eba3e0a9fc
GDScript: Support % in shorthand for get_node
...
The `%` is used in scene unique nodes. Now `%` can also be used instead
of `$` for the shorthand, besides being allowed generally anywhere in
the path as the prefix for a node name.
2022-05-27 13:46:18 -03:00
f2a7bb6b51
Merge pull request #59943 from jordigcs/gdscript_warning_enums
...
Add enum values (Ignore, Warn, Error) to GDScript warnings
2022-05-26 00:52:01 +02:00
320cf5d84c
Use blank line instead of @desc: for doc comments
2022-05-25 19:01:41 +03:00
1b76a9d705
GDScript: Fix lambda captures in default argument values
2022-05-23 21:38:31 -03:00
969f1980d2
GDScript: Fix if after lambda being seen as ternary
2022-05-23 21:13:25 -03:00
0a28b4cd94
GDScript: Do not allow standalone lambdas
...
They cannot be accessed in this case, so an error is shown to avoid
misleading the uses, especially in case of named lambdas.
2022-05-23 12:25:03 -03:00
e22255edaf
Merge pull request #55201 from Scony/fix-unreachable-code-false-positive
2022-05-18 16:04:12 +02:00
746dddc067
Replace most uses of Map by HashMap
...
* Map is unnecessary and inefficient in almost every case.
* Replaced by the new HashMap.
* Renamed Map to RBMap and Set to RBSet for cases that still make sense
(order matters) but use is discouraged.
There were very few cases where replacing by HashMap was undesired because
keeping the key order was intended.
I tried to keep those (as RBMap) as much as possible, but might have missed
some. Review appreciated!
2022-05-16 10:37:48 +02:00
8870e1c75d
Fix first value update
2022-05-12 19:11:33 -04:00
8b7c7f5a75
Add a new HashMap implementation
...
Adds a new, cleaned up, HashMap implementation.
* Uses Robin Hood Hashing (https://en.wikipedia.org/wiki/Hash_table#Robin_Hood_hashing ).
* Keeps elements in a double linked list for simpler, ordered, iteration.
* Allows keeping iterators for later use in removal (Unlike Map<>, it does not do much
for performance vs keeping the key, but helps replace old code).
* Uses a more modern C++ iterator API, deprecates the old one.
* Supports custom allocator (in case there is a wish to use a paged one).
This class aims to unify all the associative template usage and replace it by this one:
* Map<> (whereas key order does not matter, which is 99% of cases)
* HashMap<>
* OrderedHashMap<>
* OAHashMap<>
2022-05-12 11:21:29 +02:00
be8eb6625e
Fix incorrect precedence of pow operator in GDScript
2022-05-12 10:09:51 +03:00
dbd7a31507
Implement exponential operator (**) to GDScript/Expressions
2022-05-11 16:30:37 +03:00
9963ae3553
Merge pull request #59863 from cdemirer/fix-match-multiple-bind-single-pattern
...
Fix issues with multiple bind patterns in match statement
2022-05-11 14:18:02 +02:00
01d13ab2c1
GDScript: Allow using self in lambdas
2022-04-24 21:49:02 -03:00
14bad75206
Add enum values (Ignore, Warn, Error) to GDScript warnings
2022-04-06 10:57:33 -05:00
3c5b9d1be3
Fix issues with multiple bind patterns in match statement
2022-04-04 15:47:08 +08:00
5ba3b993d5
Merge pull request #59694 from vnen/gdscript-better-call-super
2022-03-30 17:58:11 +02:00
be718285f7
GDScript: Fix issues with completion and super calls
...
- Make call errors use the call node instead of the calle, which will be
empty on super calls.
- Don't allow `super()` to be used within lambdas.
2022-03-30 11:58:29 -03:00
0584387918
Fix autocompletion of static methods in built-in types in GDScript
2022-03-30 17:40:41 +03:00
7befa7234d
Merge pull request #58971 from Chaosus/gds_multiline_annotation
2022-03-22 08:25:37 +03:00
8a6ab899ec
Add an error emitting when the @export_flags arg count is exceeded
2022-03-16 17:12:15 +03:00
85488f12f3
Allow making multiline annotations in GDScript
2022-03-10 10:56:14 +03:00
ae0026bc7b
Make 'is_attribute' false during parse error to prevent crash
2022-02-18 12:52:46 +00:00
317cd0b19a
Refactor some object type checking code with cast_to
...
Less stringly typed logic, and less String allocations and comparisons.
2022-02-08 10:08:34 +01:00
89eb6d372d
Merge pull request #57591 from vnen/gdscript-enum-fixes
2022-02-04 13:49:15 +01:00
ad6e2e82a9
GDScript: Consolidate behavior for assigning enum types
...
This makes sure that assigning values to enum-typed variables are
consistent. Same enum is always valid, different enum is always
invalid (without casting) and assigning `int` creates a warning
if there is no casting.
There are new test cases to ensure this behavior doesn't break in
the future.
2022-02-03 13:32:16 -03:00
b5f524d4c0
Merge pull request #55433 from V-Sekai/prev_operand_nullptr_check
...
Check for nullptr expression in parse_precedence function
2022-01-22 20:31:45 +01:00
182a36db47
Merge pull request #55214 from Scony/fix-gdscript-crash-2
...
Fix GDScript parser crash on 'dollar mixed with assignment' expression
2022-01-22 20:30:54 +01:00
91909ef801
Merge pull request #55625 from cdemirer/fix-type-guessing-and-gdscript-parser-printing
...
Fix `--test gdscript-parser` crash
2022-01-17 20:17:02 +01:00
858bcd5058
Fix various typos
...
Found via `codespell -q 3 -S ./thirdparty,*.po,./DONORS.md -L ackward,ang,ans,ba,beng,cas,childs,childrens,dof,doubleclick,expct,fave,findn,gird,hist,inh,inout,leapyear,lod,nd,numer,ois,ony,paket,ro,seeked,sinc,switchs,te,uint,varn,vew`
2022-01-13 23:20:01 -05:00
49482966ec
Merge pull request #55715 from nathanfranke/enum-ordered
2022-01-10 17:19:52 +01:00
8f8c3f4b4c
Merge pull request #56342 from NNesh/fix/class-completion
2022-01-10 17:07:08 +01:00
1a1ee43e3e
Fixed completion showing for class members
2022-01-08 01:49:18 +05:00
6d4ed65f4c
Merge pull request #56483 from vnen/gdscript-warning-annotation
...
Add annotation to ignore warnings
2022-01-05 09:05:56 +01:00
fd643c903d
GDScript: Add annotation to ignore warnings
2022-01-04 09:32:43 -03:00
fe52458154
Update copyright statements to 2022
...
Happy new year to the wonderful Godot community!
2022-01-03 21:27:34 +01:00