mirror of
https://github.com/godotengine/godot.git
synced 2025-10-19 16:03:29 +00:00
Style: Set clang-format Standard to Cpp11
For us, it practically only changes the fact that `A<A<int>>` is now used instead of the C++03 compatible `A<A<int> >`. Note: clang-format 10+ changed the `Standard` arguments to fully specified `c++11`, `c++14`, etc. versions, but we can't use `c++17` now if we want to preserve compatibility with clang-format 8 and 9. `Cpp11` is still supported as deprecated alias for `Latest`.
This commit is contained in:
parent
c5d76139dc
commit
cb282c6ef0
247 changed files with 794 additions and 794 deletions
|
@ -1139,16 +1139,16 @@ NativeScriptLanguage *NativeScriptLanguage::singleton;
|
|||
|
||||
void NativeScriptLanguage::_unload_stuff(bool p_reload) {
|
||||
|
||||
Map<String, Ref<GDNative> > erase_and_unload;
|
||||
Map<String, Ref<GDNative>> erase_and_unload;
|
||||
|
||||
for (Map<String, Map<StringName, NativeScriptDesc> >::Element *L = library_classes.front(); L; L = L->next()) {
|
||||
for (Map<String, Map<StringName, NativeScriptDesc>>::Element *L = library_classes.front(); L; L = L->next()) {
|
||||
|
||||
String lib_path = L->key();
|
||||
Map<StringName, NativeScriptDesc> classes = L->get();
|
||||
|
||||
if (p_reload) {
|
||||
|
||||
Map<String, Ref<GDNative> >::Element *E = library_gdnatives.find(lib_path);
|
||||
Map<String, Ref<GDNative>>::Element *E = library_gdnatives.find(lib_path);
|
||||
Ref<GDNative> gdn;
|
||||
|
||||
if (E) {
|
||||
|
@ -1169,7 +1169,7 @@ void NativeScriptLanguage::_unload_stuff(bool p_reload) {
|
|||
}
|
||||
}
|
||||
|
||||
Map<String, Ref<GDNative> >::Element *E = library_gdnatives.find(lib_path);
|
||||
Map<String, Ref<GDNative>>::Element *E = library_gdnatives.find(lib_path);
|
||||
Ref<GDNative> gdn;
|
||||
|
||||
if (E) {
|
||||
|
@ -1204,7 +1204,7 @@ void NativeScriptLanguage::_unload_stuff(bool p_reload) {
|
|||
erase_and_unload.insert(lib_path, gdn);
|
||||
}
|
||||
|
||||
for (Map<String, Ref<GDNative> >::Element *E = erase_and_unload.front(); E; E = E->next()) {
|
||||
for (Map<String, Ref<GDNative>>::Element *E = erase_and_unload.front(); E; E = E->next()) {
|
||||
String lib_path = E->key();
|
||||
Ref<GDNative> gdn = E->get();
|
||||
|
||||
|
@ -1247,7 +1247,7 @@ NativeScriptLanguage::NativeScriptLanguage() {
|
|||
|
||||
NativeScriptLanguage::~NativeScriptLanguage() {
|
||||
|
||||
for (Map<String, Ref<GDNative> >::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
for (Map<String, Ref<GDNative>>::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
|
||||
Ref<GDNative> lib = L->get();
|
||||
// only shut down valid libs, duh!
|
||||
|
@ -1385,7 +1385,7 @@ void NativeScriptLanguage::get_recognized_extensions(List<String> *p_extensions)
|
|||
void NativeScriptLanguage::get_public_functions(List<MethodInfo> *p_functions) const {
|
||||
}
|
||||
|
||||
void NativeScriptLanguage::get_public_constants(List<Pair<String, Variant> > *p_constants) const {
|
||||
void NativeScriptLanguage::get_public_constants(List<Pair<String, Variant>> *p_constants) const {
|
||||
}
|
||||
|
||||
void NativeScriptLanguage::profiling_start() {
|
||||
|
@ -1679,7 +1679,7 @@ void NativeScriptLanguage::init_library(const Ref<GDNativeLibrary> &lib) {
|
|||
// See if this library was "registered" already.
|
||||
const String &lib_path = lib->get_current_library_path();
|
||||
ERR_FAIL_COND_MSG(lib_path.length() == 0, lib->get_name() + " does not have a library for the current platform.");
|
||||
Map<String, Ref<GDNative> >::Element *E = library_gdnatives.find(lib_path);
|
||||
Map<String, Ref<GDNative>>::Element *E = library_gdnatives.find(lib_path);
|
||||
|
||||
if (!E) {
|
||||
Ref<GDNative> gdn;
|
||||
|
@ -1719,7 +1719,7 @@ void NativeScriptLanguage::register_script(NativeScript *script) {
|
|||
void NativeScriptLanguage::unregister_script(NativeScript *script) {
|
||||
MutexLock lock(mutex);
|
||||
|
||||
Map<String, Set<NativeScript *> >::Element *S = library_script_users.find(script->lib_path);
|
||||
Map<String, Set<NativeScript *>>::Element *S = library_script_users.find(script->lib_path);
|
||||
if (S) {
|
||||
S->get().erase(script);
|
||||
if (S->get().size() == 0) {
|
||||
|
@ -1733,7 +1733,7 @@ void NativeScriptLanguage::unregister_script(NativeScript *script) {
|
|||
|
||||
void NativeScriptLanguage::call_libraries_cb(const StringName &name) {
|
||||
// library_gdnatives is modified only from the main thread, so it's safe not to use mutex here
|
||||
for (Map<String, Ref<GDNative> >::Element *L = library_gdnatives.front(); L; L = L->next()) {
|
||||
for (Map<String, Ref<GDNative>>::Element *L = library_gdnatives.front(); L; L = L->next()) {
|
||||
|
||||
if (L->get().is_null()) {
|
||||
continue;
|
||||
|
@ -1755,7 +1755,7 @@ void NativeScriptLanguage::frame() {
|
|||
#ifndef NO_THREADS
|
||||
if (has_objects_to_register) {
|
||||
MutexLock lock(mutex);
|
||||
for (Set<Ref<GDNativeLibrary> >::Element *L = libs_to_init.front(); L; L = L->next()) {
|
||||
for (Set<Ref<GDNativeLibrary>>::Element *L = libs_to_init.front(); L; L = L->next()) {
|
||||
init_library(L->get());
|
||||
}
|
||||
libs_to_init.clear();
|
||||
|
@ -1834,7 +1834,7 @@ void NativeReloadNode::_notification(int p_what) {
|
|||
MutexLock lock(NSL->mutex);
|
||||
NSL->_unload_stuff(true);
|
||||
|
||||
for (Map<String, Ref<GDNative> >::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
for (Map<String, Ref<GDNative>>::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
|
||||
Ref<GDNative> gdn = L->get();
|
||||
|
||||
|
@ -1869,7 +1869,7 @@ void NativeReloadNode::_notification(int p_what) {
|
|||
MutexLock lock(NSL->mutex);
|
||||
|
||||
Set<StringName> libs_to_remove;
|
||||
for (Map<String, Ref<GDNative> >::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
for (Map<String, Ref<GDNative>>::Element *L = NSL->library_gdnatives.front(); L; L = L->next()) {
|
||||
|
||||
Ref<GDNative> gdn = L->get();
|
||||
|
||||
|
@ -1904,7 +1904,7 @@ void NativeReloadNode::_notification(int p_what) {
|
|||
((void (*)(void *))proc_ptr)((void *)&L->key());
|
||||
}
|
||||
|
||||
for (Map<String, Set<NativeScript *> >::Element *U = NSL->library_script_users.front(); U; U = U->next()) {
|
||||
for (Map<String, Set<NativeScript *>>::Element *U = NSL->library_script_users.front(); U; U = U->next()) {
|
||||
for (Set<NativeScript *>::Element *S = U->get().front(); S; S = S->next()) {
|
||||
NativeScript *script = S->get();
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue