summaryrefslogtreecommitdiff
path: root/core/extension
AgeCommit message (Collapse)Author
2021-08-13Refactors the memnew_placement.AndreaCatania
With this commit the macro `memnew_placement` uses the standard memory placement syntax: `new (mem) TheClass()`, and removes the outdated and not used syntax: ``` _ALWAYS_INLINE_ void *operator new(size_t p_size, void *p_pointer, size_t check, const char *p_description) { ``` Thanks to this change, the function `memnew_placement` call is compatible with any class, and can also initialize classes with non-empty constructor: ``` // This is valid, like before. memnew_placement(mem, Variant); // This works too: memnew_placement(mem, Variant(123)); ```
2021-08-09Rename GDNative call error enum values to use GDNATIVE prefixGeorge Marques
To make sure it does not clash with other libraries.
2021-08-05Improve extension systemGeorge Marques
- Fix library loading and initialization. - Add extra methods/parameters in the interface needed by extenstions. - Add Variant destructors and functions for extracting values and creating Variants from values.
2021-08-05Improve extension API dumpGeorge Marques
- Fix type size information. - Validate sizes at compile time (for the current build configuration only). - Normalize type names. - Add extra information.
2021-07-27Change Variant bool conversion to uint8_tGeorge Marques
This ensures more portable conversion since not every path assume bool is 32-bits and there's no loss converting to 8-bits anyway.
2021-07-25Fix dead code in `gdnative_interface.cpp`Nicholas Huelin
This pull request fixes dead code found in `gdnative_interface.cpp`
2021-07-25Merge pull request #50809 from akien-mga/iterators-const-referencesRémi Verschelde
2021-07-25Use const references where possible for List range iteratorsRémi Verschelde
2021-07-25Fix various typos with codespellluz paz
Found via `codespell -q 3 -S ./thirdparty,*.po,./DONORS.md -L ackward,ang,ans,ba,beng,cas,childs,childrens,dof,doubleclick,fave,findn,hist,inout,leapyear,lod,nd,numer,ois,ony,paket,seeked,sinc,switchs,te,uint`
2021-07-23Use C++ iterators for Lists in many situationsAaron Franke
2021-07-08Redo how instance bindings workreduz
* The harcoded 8 slots are no more and impose limits in the new extension system. * New system is limitless, although it will impose small performance hit with a mutex. * Use a token to request the instance binding. **Warning**: Mono will most likely break as a result of this, will need to be modified to use the new system.
2021-06-25Implement native extension systemreduz
* Deprecates GDNative in favor of a simpler, lower level interface. * New extension system allows registering core engine classes. * Simple header interface in gdnative_interace.h