summaryrefslogtreecommitdiffstats
path: root/modules/gdscript/tests/scripts/analyzer/features
Commit message (Collapse)AuthorAgeFilesLines
* Core: Fix built-in enum constant bindingsDanil Alexeev2024-11-222-0/+53
|
* Always add decimal when printing floatkobewi2024-10-235-37/+37
|
* Implement typed dictionariesThaddeus Crews2024-09-048-0/+264
|
* GDScript: Replace `assert()` with `Utils.check()` in testsDanil Alexeev2024-08-2810-215/+209
|
* GDScript: Fix common mismatched external parser errorsrune-scape2024-07-3112-0/+50
|
* GDScript: Fix some export annotation issuesDanil Alexeev2024-05-131-5/+5
|
* Style: Trim trailing whitespace and ensure newline at EOFRémi Verschelde2024-05-082-2/+0
| | | | Found by apply the file_format checks again via #91597.
* Add PackedVector4Array Variant typeK. S. Ernest (iFire) Lee2024-05-032-0/+15
| | | | | Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com> Co-authored-by: Rémi Verschelde <rverschelde@gmail.com>
* GDScript: Fix access non-static members in static contextDanil Alexeev2024-05-012-0/+76
|
* GDScript: Allow casting enum to intGeorge Marques2024-04-122-0/+11
| | | | | An enum value is always an integer so the cast is valid. The code here now consider this case to avoid giving an error message.
* Merge pull request #90448 from vnen/gdscript-infer-string-formatRémi Verschelde2024-04-102-0/+8
|\ | | | | | | GDScript: Infer type with string format operator
| * GDScript: Infer type with string format operatorGeorge Marques2024-04-102-0/+8
| | | | | | | | | | | | | | If the left value type is known to be String, assume the format operator (`%`) will return a string, since it works with any type in the right hand side. This is also used by type inference even if the right hand type is unknown at compile time.
* | GDScript: Don't warn on unassigned for builtin-typed variablesGeorge Marques2024-04-104-1/+13
|/ | | | | | | | | | | If the type of a variable is a built-in Variant type, then it will automatically be assigned a default value based on the type. This means that the explicit initialization may be unnecessary. Thus this commit removes the warning in such case. This also changes the meaning of the unassigned warning to happen when the variable is used before being assigned, not when it has zero assignments.
* GDScript: Fix `@warning_ignore` annotation issuesDanil Alexeev2024-03-126-19/+221
|
* GDScript: Add `@export_storage` annotationDanil Alexeev2023-12-192-13/+12
|
* GDScript: Add return type covariance and parameter type contravarianceDanil Alexeev2023-09-284-0/+54
|
* GDScript: Improve call analysisDanil Alexeev2023-09-212-0/+5
| | | | | | * Add missing `UNSAFE_CALL_ARGUMENT` warning. * Fix `Object` constructor. * Display an error for non-existent static methods.
* Merge pull request #81332 from ↵Rémi Verschelde2023-09-202-0/+29
|\ | | | | | | | | | | dalexeev/gds-fix-update-array-literal-in-weak-context GDScript: Don't make array literal typed in weak type context
| * GDScript: Don't make array literal typed in weak type contextDanil Alexeev2023-09-052-0/+29
| |
* | GDScript: Fix subscript resolution for constant non-metatypesDanil Alexeev2023-09-192-0/+28
| |
* | GDScript: Add check for `super()` methods not being implementedocean (they/them)2023-09-172-0/+24
|/
* Merge pull request #80964 from dalexeev/gds-allow-use-local-consts-as-typesYuri Sizov2023-08-253-0/+58
|\ | | | | | | GDScript: Allow use local constants as types
| * GDScript: Allow use local constants as typesDanil Alexeev2023-08-253-0/+58
| |
* | GDScript: Fix lambda resolution with cyclic referencesDanil Alexeev2023-08-252-0/+39
|/
* GDScript: Fix "Identifier not found" error when accessing inner class from ↵Danil Alexeev2023-08-112-0/+26
| | | | inside
* GDScript: Fix bug with identifier shadowed below in current scopeDanil Alexeev2023-07-261-1/+1
|
* Fix for not being able to ignore shadowing warnings on class scopejpcerrone2023-07-242-3/+3
|
* GDScript: fix regression when checking for virtual function implementation.ocean (they/them)2023-06-214-23/+0
| | | | | | | | | | | | Unfortunately it appears the virtual function checks in #77324 are not trustworthy at runtime, because objects can have scripts attached, but this information is not always available at compile-time. These checks need to be removed. The rest of the PR is still useful, making all method flags available to the analyzer, so a full revert isn't necessary/desirable. This reopens #76938, which will need another solution.
* Merge pull request #74741 from vnen/variant-not-for-everyoneRémi Verschelde2023-06-182-0/+576
|\ | | | | | | Allow boolean operators for all Variant types
| * GDScript: Allow boolean operators between any typesGeorge Marques2023-03-102-0/+576
| | | | | | | | | | To make consistent with previous behavior. Mostly to be used in conditions for `if` and `while`.
* | GDScript: add errors when calling unimplemented virtual functionsocean (they/them)2023-06-152-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | This PR does a small refactor of how method flags are handled in the GDScript analyzer. This way, it adds support for the analyzer to use any of MethodInfo's flags, where previously it could only use METHOD_FLAG_STATIC and METHOD_FLAG_VARARG. As a side-effect, this also normalizes behavior between editor and release templates, which fixes #76938. The tests added also brought a different issue to light, where using `super()` appears to generate a return variable discarded on calling super's _init(), which doesn't have a return value. This should be tackled in a different PR, which will have to change the output of this PR's tests.
* | Merge pull request #77351 from anvilfolk/super-discardRémi Verschelde2023-06-152-0/+11
|\ \ | | | | | | | | | GDScript: do not RETURN_VALUE_DISCARDED for `super()` inside `_init()`
| * | GDScript: do not warn of return value discarded for super() inside _init()ocean (they/them)2023-05-222-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | DO NOT BATCH MERGE WITH #77324, WILL RESULT IN BROKEN CI Currently, calling super() inside _init() throws a RETURN_VALUE_DISCARDED warning. The analyzer identifies super() as being a constructor, which therefore returns an object of the relevant class. However, super() isn't really a constructor by itself: in this case, it is _part_ of the constructor, and so doesn't "return" a value. A test case for this is already in #77324, which contains the warning. I am duplicating it here, without the warning, and it should conflict with the other PR.
* | | Merge pull request #75419 from vonagam/fix-super-classes-in-array-literalsRémi Verschelde2023-06-141-2/+2
|\ \ \ | |/ / |/| | | | | GDScript: Allow elements of a parent class in a typed array literal
| * | GDScript: Allow elements of a parent class in a typed array literalDmitrii Maganov2023-03-281-2/+2
| | |
* | | Merge pull request #76412 from dalexeev/gds-reorganize-warningsRémi Verschelde2023-04-282-2/+2
|\ \ \ | | | | | | | | | | | | GDScript: Reorganize and unify warnings
| * | | GDScript: Reorganize and unify warningsDanil Alexeev2023-04-282-2/+2
| |/ /
* | | Merge pull request #75014 from vonagam/assert-literal-falseRémi Verschelde2023-04-282-0/+8
|\ \ \ | |/ / |/| | | | | GDScript: Allow usage of literal false in assert without a warning
| * | GDScript: Allow usage of literal false in assert without a warningDmitrii Maganov2023-03-172-0/+8
| |/
* / GDScript: Fix false positive `REDUNDANT_AWAIT` warningDanil Alexeev2023-03-161-1/+1
|/
* Fix GDScript code style regarding colonDanil Alexeev2023-03-057-24/+24
|
* GDScript: Fix range regressionDmitrii Maganov2023-02-242-0/+9
|
* GDScript: Fix usage of enum value as range argumentDmitrii Maganov2023-02-232-0/+11
|
* Merge pull request #73705 from anvilfolk/doublewoopsieRémi Verschelde2023-02-212-0/+25
|\ | | | | | | Added check for null objects in gdscript typed assign.
| * Added check for null objects in gdscript typed assign.ocean (they/them)2023-02-212-0/+25
| |
* | GDScript: Fix override signature check of script inheritanceGeorge Marques2023-02-212-0/+12
|/ | | | | Avoid treating the super class as a meta type for signature check, since it is looking at the instance level for that.
* Merge pull request #73590 from vnen/gdscript-global-scope-enumsRémi Verschelde2023-02-202-0/+39
|\ | | | | | | Make global scope enums accessible as types in GDScript
| * Make global scope enums accessible as types in GDScriptGeorge Marques2023-02-192-0/+39
| | | | | | | | | | | | Add functions to CoreConstant so enums can be properly deduced. Also add the enums in release builds to make consistent with ClassDB enums and avoid differences in script compilation between debug and release.
* | Merge pull request #73489 from vonagam/type-check-nodeRémi Verschelde2023-02-202-0/+129
|\ \ | | | | | | | | | GDScript: Rework type check
| * | GDScript: Rework type checkDmitrii Maganov2023-02-172-0/+129
| |/