Age | Commit message (Collapse) | Author |
|
The binary search algorithm used to lookup character codes in the table
relies that the data must be ordered. This fixes `to_lower()` string
method to convert upper case to lower case properly, so that the
algorithm doesn't terminate prematurely.
Co-authored-by: AndreevAndrei (avandrei) <avandrei@MacBookAAV.local>
|
|
|
|
This can happen when chaining calls to various string methods when the
string is empty.
|
|
Background: lstrip and rstrip were broken by changes to String in:
0e29f7974b59e4440cf02e1388fb9d8ab2b5c5fd
which removed it's access to Vector::find(CharType).
Moved Vector's find up into CowData so it can be shared by Vector and String.
Added String::find_char using CowData::find.
Implemented rstrip and lstrip using find_char.
Added a few tests for String rstrip and lstrip.
|
|
As per the C++ standard 21.3.4.1 for std::string:
Returns: If pos < size(), returns data()[pos]. Otherwise, if pos ==
size(), the const version returns charT(). Otherwise, the behavior is
undefined.
Since the behavior is undefined Godot now does the same thing for const
and non-const versions of operator[].
This fixes #21242 and fixes #22221.
|
|
Happy new year to the wonderful Godot community!
|
|
* There were spaces unequally inside the function definitions.
* camelcase_to_underscore() should also work for numbers inside of the camel case.
* Removed the builtin concept
* Capitalize descriptions from methods too.
* Match the visual script functions by removing the empty arguments "( )"
* Add some test cases
|
|
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.
|
|
Using v1.11.0 from https://github.com/lucasdemarchi/codespell
|
|
Using `misc/scripts/fix_headers.py` on all Godot files.
Some missing header guards were added, and the header inclusion order
was fixed in the Bullet module.
|
|
Happy new year to the wonderful Godot community!
|
|
|
|
|
|
|
|
|
|
I can show you the code
Pretty, with proper whitespace
Tell me, coder, now when did
You last write readable code?
I can open your eyes
Make you see your bad indent
Force you to respect the style
The core devs agreed upon
A whole new world
A new fantastic code format
A de facto standard
With some sugar
Enforced with clang-format
A whole new world
A dazzling style we all dreamed of
And when we read it through
It's crystal clear
That now we're in a whole new world of code
|
|
|
|
Redone the commit based on the input in
https://github.com/godotengine/godot/pull/7851 . Not all warnings were
fixed but it's a start.
|
|
They do not play well with clang-format which aligns the `//` part
with the rest of the code block, thus producing badly indented commented code.
|
|
As advised by @reduz, as tests depend on other libs.
|