summaryrefslogtreecommitdiff
path: root/modules/gdscript/gdscript_parser.cpp
AgeCommit message (Collapse)Author
2018-09-27Fix invalid comparison warnings: [-Wbool-compare] and [-Wenum-compare]Rémi Verschelde
Fixes the following GCC 5 warnings and actual bugs: ``` drivers/unix/net_socket_posix.cpp:562:28: warning: comparison between 'enum IP::Type' and 'enum NetSocket::Type' [-Wenum-compare] modules/gdscript/gdscript_function.cpp:792:26: warning: comparison of constant '17' with boolean expression is always true [-Wbool-compare] modules/gdscript/gdscript_function.cpp:792:26: warning: logical not is only applied to the left hand side of comparison [-Wlogical-not-parentheses] modules/gdscript/gdscript_parser.cpp:5082:58: warning: comparison of constant '6' with boolean expression is always false [-Wbool-compare] modules/gdscript/gdscript_parser.cpp:5082:58: warning: logical not is only applied to the left hand side of comparison [-Wlogical-not-parentheses] modules/mbedtls/stream_peer_mbed_tls.cpp:286:45: warning: comparison between 'enum StreamPeerTCP::Status' and 'enum StreamPeerSSL::Status' [-Wenum-compare] modules/mbedtls/stream_peer_mbed_tls.cpp:313:45: warning: comparison between 'enum StreamPeerTCP::Status' and 'enum StreamPeerSSL::Status' [-Wenum-compare] ```
2018-09-19GDScript: Error on empty blocks at the end of fileGeorge Marques
Fix #15415
2018-09-19GDScript: Forbid enum values to shadow constantsGeorge Marques
- Don't allow constants to shadow parent members. - Fix a spelling mistake. Fix #13175
2018-09-19GDScript: Allow Object constants to be used with qualifierGeorge Marques
Fix #15125
2018-09-16test for depreciacion warnings only on debug buildsMariusz Chwalba
Fix adherence to clang-format rules
2018-09-15Add GDScript slave keyword deprecation warning.Fabio Alessandrelli
2018-09-15Clearly deprecate sync too in favor of remotesync.Fabio Alessandrelli
NOTE: This changes the RPC_MODE_* enum values. Games should be re-exported. GDNative rebuilt.
2018-09-15Rename slave keyword to puppetFabio Alessandrelli
The slave keyword will still be available as deprecated in 3.1 but will be dropped from future releases.
2018-09-13Merge pull request #21982 from luzpaz/misc-typosRémi Verschelde
Misc. typos
2018-09-12Misc. typosluz.paz
Found via `codespell -q 3 -I ../godot-word-whitelist.txt --skip="./thirdparty,*.po"`
2018-09-12Make core/ includes absolute, remove subfolders from include pathRémi Verschelde
This allows more consistency in the manner we include core headers, where previously there would be a mix of absolute, relative and include path-dependent includes.
2018-08-27Merge pull request #21449 from vnen/gdscript-builtin-isRémi Verschelde
Allow `is` operator to test built-in types
2018-08-27Merge pull request #21369 from Noshyaar/exportflagRémi Verschelde
Deprecating bit flags export with no hint text
2018-08-26GDScript: Allow `is` operator to test built-in typesGeorge Marques
2018-08-24Deprecating bit flags export with no hint textPoommetee Ketson
2018-08-24Make some debug prints verbose-only, remove othersRémi Verschelde
2018-08-21GDScript: Ignore unused arguments/local vars that start with _George Marques
Makes it simple to ignore particular arguments without adding special comments, especially in engine-defined functions.
2018-08-21GDScript: Forbid invalid identifiers in match bindingsGeorge Marques
Also forbid shadowing a variable from an upper scope.
2018-08-14Add custom icons to script classes.Will Nations
2018-08-13Remove usage console spamChaosus
2018-08-10Added system for GDScript warningsGeorge Marques
- Count and panel per script. - Ability to disable warnings per script using special comments. - Ability to disable warnings globally using Project Settings. - Option to treat enabled warnings as errors.
2018-07-31Allow some non-integer built-in constants in gdscriptBernhard Liebl
2018-07-26GDScript: Fix parse error in string formattingGeorge Marques
2018-07-25GDScript: Add type inference syntax for function argumentsGeorge Marques
2018-07-25GDScript: Fix type detection for String formatting operatorGeorge Marques
2018-07-25GDScript: Allow accessing constants of outer classesGeorge Marques
2018-07-25GDScript: Fix bogus error when a cursor token is found on classGeorge Marques
2018-07-25GDScript: Fix mismatching between export hint and type hintGeorge Marques
2018-07-25GDScript: Allow inherited method to add optional argumentsGeorge Marques
Also show the parent method signature in the error message.
2018-07-25GDScript: Look up local scope first for detecting typeGeorge Marques
2018-07-26Reduce unnecessary COW on Vector by make writing explicitHein-Pieter van Braam
This commit makes operator[] on Vector const and adds a write proxy to it. From now on writes to Vectors need to happen through the .write proxy. So for instance: Vector<int> vec; vec.push_back(10); std::cout << vec[0] << std::endl; vec.write[0] = 20; Failing to use the .write proxy will cause a compilation error. In addition COWable datatypes can now embed a CowData pointer to their data. This means that String, CharString, and VMap no longer use or derive from Vector. _ALWAYS_INLINE_ and _FORCE_INLINE_ are now equivalent for debug and non-debug builds. This is a lot faster for Vector in the editor and while running tests. The reason why this difference used to exist is because force-inlined methods used to give a bad debugging experience. After extensive testing with modern compilers this is no longer the case.
2018-07-20Rewrite code completionGeorge Marques
- Use data type struct from the parser. - Avail from type hints when type can't be guessed. - Consider inner classes and other scripts when looking for candidates.
2018-07-20Add ability to infer variable type from assigned valueGeorge Marques
Syntax: var x : = 42 Infers the type of "x" to be an integer.
2018-07-20Add editor highlight for type-safe linesGeorge Marques
The line number is hightlighted to indicate that the line contains only type-safe code.
2018-07-20Fix line number detection in some parser nodesGeorge Marques
2018-07-20Use type information to enable GDScript introspectionGeorge Marques
This makes the Script API provide accurate information when requesting property or method info.
2018-07-20Add static type checks in the parserGeorge Marques
- Resolve types for all identifiers. - Error when identifier is not found. - Match return type and error when not returning a value when it should. - Check unreachable code (code after sure return). - Match argument count and types for function calls. - Determine if return type of function call matches the assignment. - Do static type check with match statement when possible. - Use type hints to determine export type. - Check compatibility between type hint and explicit export type.
2018-07-20Store type hint of declared identifiersGeorge Marques
2018-07-20Move inheritance resolution to the parserGeorge Marques
2018-07-20Add typing syntaxGeorge Marques
2018-07-15Global class names (and GDScript support for it)Juan Linietsky
2018-06-18Add proper type information to array propertyBojidar Marinov
Part of #19158
2018-05-29New sync keywords in GDScript, NativeScript, MonoFabio Alessandrelli
2018-05-29Refactor RPCMode enum and checksFabio Alessandrelli
2018-05-29Revert "RPCMode refactor, more sync modes"Max Hilbrunner
2018-05-29Merge pull request #19021 from Faless/rpc_sync_fixMax Hilbrunner
RPCMode refactor, more sync modes
2018-05-28Enable singletons to be recognized as constant expressionsGeorge Marques
Fix #14681
2018-05-26New sync keywords in GDScript, NativeScript, MonoFabio Alessandrelli
2018-05-26Refactor RPCMode enum and checksFabio Alessandrelli
2018-05-03Merge pull request #16418 from bojidar-bg/15961-gdscript-array-exportRémi Verschelde
Allow exporting arrays of resources in GDScript