Style: Remove unnecessary semicolons from core
Semicolons are not necessary after function definitions or control flow blocks, and having some code use them makes things inconsistent (and occasionally can mess up `clang-format`'s formatting). Removing them is tedious work though, I had to do this manually (regex + manual review) as I couldn't find a tool for that. All other code folders would need to get the same treatment.
This commit is contained in:
@@ -44,7 +44,7 @@ Variant PackedDataContainer::getvar(const Variant &p_key, bool *r_valid) const {
|
||||
|
||||
int PackedDataContainer::size() const {
|
||||
return _size(0);
|
||||
};
|
||||
}
|
||||
|
||||
Variant PackedDataContainer::_iter_init_ofs(const Array &p_iter, uint32_t p_offset) {
|
||||
Array ref = p_iter;
|
||||
@@ -124,7 +124,7 @@ uint32_t PackedDataContainer::_type_at_ofs(uint32_t p_ofs) const {
|
||||
uint32_t type = decode_uint32(r);
|
||||
|
||||
return type;
|
||||
};
|
||||
}
|
||||
|
||||
int PackedDataContainer::_size(uint32_t p_ofs) const {
|
||||
const uint8_t *rd = data.ptr();
|
||||
@@ -139,10 +139,10 @@ int PackedDataContainer::_size(uint32_t p_ofs) const {
|
||||
} else if (type == TYPE_DICT) {
|
||||
uint32_t len = decode_uint32(r + 4);
|
||||
return len;
|
||||
};
|
||||
}
|
||||
|
||||
return -1;
|
||||
};
|
||||
}
|
||||
|
||||
Variant PackedDataContainer::_key_at_ofs(uint32_t p_ofs, const Variant &p_key, bool &err) const {
|
||||
const uint8_t *rd = data.ptr();
|
||||
@@ -368,7 +368,7 @@ Variant PackedDataContainerRef::_iter_get(const Variant &p_iter) {
|
||||
|
||||
bool PackedDataContainerRef::_is_dictionary() const {
|
||||
return from->_type_at_ofs(offset) == PackedDataContainer::TYPE_DICT;
|
||||
};
|
||||
}
|
||||
|
||||
void PackedDataContainerRef::_bind_methods() {
|
||||
ClassDB::bind_method(D_METHOD("size"), &PackedDataContainerRef::size);
|
||||
@@ -389,4 +389,4 @@ Variant PackedDataContainerRef::getvar(const Variant &p_key, bool *r_valid) cons
|
||||
|
||||
int PackedDataContainerRef::size() const {
|
||||
return from->_size(offset);
|
||||
};
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user