-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Xcode16 build fix #2585
base: develop
Are you sure you want to change the base?
Xcode16 build fix #2585
Commits on Sep 17, 2024
-
Configuration menu - View commit details
-
Copy full SHA for 576c558 - Browse repository at this point
Copy the full SHA 576c558View commit details
Commits on Sep 24, 2024
-
Make
LLPointer
equality comparisons accept not-identical types.That is, both `LLPointer::operator==()` and `operator!=()` and the free function `operator==()` and `operator!=()` now accept pointer types other than the type of the subject `LLPointer`, letting the compiler apply implicit pointer conversions or diagnose an error.
Configuration menu - View commit details
-
Copy full SHA for 705fd68 - Browse repository at this point
Copy the full SHA 705fd68View commit details -
LLConstPointer<T> is the same as LLPointer<const T>.
Instead of restating the whole class, requiring changes to be made in parallel (which has already failed), just make a template alias.
Configuration menu - View commit details
-
Copy full SHA for 1a682de - Browse repository at this point
Copy the full SHA 1a682deView commit details
Commits on Sep 25, 2024
-
Use copy-and-swap idiom for LLPointer's assignment operators.
This affords strong exception safety. Also, eliminating the conditional may improve speed.
Configuration menu - View commit details
-
Copy full SHA for 98c829a - Browse repository at this point
Copy the full SHA 98c829aView commit details -
Explain why apparently redundant LLPointer methods are necessary.
Given templated constructors and assignment operators, it's tempting to remove specific constructors and assignment operators with the same LLPointer<Type> parameters. That turns out to be a mistake. Add comments to warn future maintainers.
Configuration menu - View commit details
-
Copy full SHA for 5d7b3ab - Browse repository at this point
Copy the full SHA 5d7b3abView commit details -
Merge pull request #2681 from secondlife/nat/xcode-16
Generalize LLPointer's comparison operators to allow comparable LLPointer types.
Configuration menu - View commit details
-
Copy full SHA for 4b2b94f - Browse repository at this point
Copy the full SHA 4b2b94fView commit details -
Configuration menu - View commit details
-
Copy full SHA for 55df732 - Browse repository at this point
Copy the full SHA 55df732View commit details
Commits on Sep 26, 2024
-
Adapt
fsyspath
for C++20 conventions.In C++20, `std::filesystem::u8path()` (that accepts a UTF-8 encoded `std::string` and returns a `std::filesystem::path`) is deprecated. Instead, to engage UTF-8 coding conversions, we're supposed to pass the `path` constructor a `std::u8string`, i.e. a `std::basic_string<char8_t>`. Since `char8_t` is a type distinct from both `char` and `unsigned char`, we must Do Something to pass a UTF-8 encoded `std::string` into `std::filesystem::path`. To avoid copying characters from a `std::string` into a temporary `std::u8string` and from there into the `std::filesystem::path`, make a `boost::transform_iterator` that accepts a `std::string_view::iterator` and adapts it to dereference `char8_t` characters. Make `fsyspath(std::string_view)` engage the base-class constructor accepting (iterator, iterator), adapting `string_view::begin()` and `end()` to deliver `char8_t` characters. Use the same tactic for `fsyspath::operator=(std::string_view)`, explicitly calling `std::filesystem::path::assign()` with the adapted iterators. To resolve ambiguities, provide both constructors and assignment operators accepting `(const std::string&)` and `(const char*)`, explicitly converting each to `std::string_view`. At the same time, `std::filesystem::path::u8string()` now returns `std::u8string` rather than `std::string`. Since `std::filesystem::path` delivers only that `std::u8string` rather than iterators into its internal representation, we can't avoid capturing it and copying to the returned `std::string`. Remove explicit `.u8string()` calls from a few existing `fsyspath` instances, now that `fsyspath` supports implicit conversion to `std::string`.
Configuration menu - View commit details
-
Copy full SHA for dc0c6d3 - Browse repository at this point
Copy the full SHA dc0c6d3View commit details -
Configuration menu - View commit details
-
Copy full SHA for 988a0fd - Browse repository at this point
Copy the full SHA 988a0fdView commit details -
#include <cmath> rather than "math.h" to avoid lerp() conflict.
GCC on Linux complains that "math.h", which hoists all the standard library math functions into the global namespace for classic C compatibility, creates a conflict between `std::lerp()` and the `lerp()` function in llmath.h. (Perhaps we should just replace our `lerp()` definition with `using std::lerp;`) Anyway, bringing in <cmath> rather than "math.h" leaves standard library math functions in the `std` namespace, avoiding the conflict.
Configuration menu - View commit details
-
Copy full SHA for 015ff3d - Browse repository at this point
Copy the full SHA 015ff3dView commit details -
Ditch our own (conflicting) definition of the lerp() function.
Hoist `std::lerp()` into the global namespace instead.
Configuration menu - View commit details
-
Copy full SHA for 6400284 - Browse repository at this point
Copy the full SHA 6400284View commit details -
Fix GCC ambiguous-reversed-operator errors for
LLKeyData
compares.`LLKeyData::operator==(const LLKeyData&)` and `operator!=(const LLKeyData&)` were not themselves `const` methods. In C++20, that can produce a fatal warning that if the compare operands were reversed, you'd get different results. Making them both `const` should fix it. While touching the method definitions, make `operator==()` more intuitive, and make `operator!=()` simply negate `operator==()` instead of restating it in reverse.
Configuration menu - View commit details
-
Copy full SHA for 6ac59d1 - Browse repository at this point
Copy the full SHA 6ac59d1View commit details -
Reinstate our lerp() function, avoid "math.h" header.
For reasons that remain unclear, MSVC likes our lerp() function better than its own std::lerp() function: publishing the latter into the global namespace, instead of defining our own, produces fatal argument conversion warnings. "math.h" publishes all of <cmath> into the global namespace, which causes a GCC conflict between std::lerp() and our lerp() function. Including <cmath> instead leaves std::lerp() in the std namespace, eliminating the conflict.
Configuration menu - View commit details
-
Copy full SHA for d7f6b96 - Browse repository at this point
Copy the full SHA d7f6b96View commit details -
Configuration menu - View commit details
-
Copy full SHA for 15dad13 - Browse repository at this point
Copy the full SHA 15dad13View commit details -
Configuration menu - View commit details
-
Copy full SHA for 452e074 - Browse repository at this point
Copy the full SHA 452e074View commit details -
Rename our lerp() to flerp(); call where MSVC balks at std::lerp().
Now the lerp() in global namespace is std::lerp(), but it remains true that for some calls to std::lerp(), MSVC issues fatal argument conversion warnings. In those places, call flerp() (our historic lerp()) instead.
Configuration menu - View commit details
-
Copy full SHA for 8a6da4d - Browse repository at this point
Copy the full SHA 8a6da4dView commit details -
Configuration menu - View commit details
-
Copy full SHA for b043ed4 - Browse repository at this point
Copy the full SHA b043ed4View commit details -
Configuration menu - View commit details
-
Copy full SHA for fcfcca9 - Browse repository at this point
Copy the full SHA fcfcca9View commit details
Commits on Sep 27, 2024
-
Configuration menu - View commit details
-
Copy full SHA for d3833b6 - Browse repository at this point
Copy the full SHA d3833b6View commit details -
Migrate ~LLPointer()'s peculiar warning case to llpointer.cpp.
This allows removing #include "llerror.h" from llpointer.h. Also remove #include "llmutex.h" as a heavy way to get <boost/functional/hash.hpp>. That requires adding #include "llmutex.h" to llimage.h, llnotifications.h, llwatchdog.cpp and llvolumemgr.cpp, which were inheriting it from llpointer.h.
Configuration menu - View commit details
-
Copy full SHA for a2b76b6 - Browse repository at this point
Copy the full SHA a2b76b6View commit details -
Automate memory management in JPEG2KEncode and JPEG2KDecode.
Instead of using strdup() and free() to store comment_text in JPEG2KEncode, store a std::string. Similarly, instead of manually managing pointers to encoder, decoder, image, stream and codestream_info in JPEG2KDecode and JPEG2KEncode, use std::unique_ptr for each, specifying their respective deleter functions.
Configuration menu - View commit details
-
Copy full SHA for d39c862 - Browse repository at this point
Copy the full SHA d39c862View commit details -
Configuration menu - View commit details
-
Copy full SHA for c7cef95 - Browse repository at this point
Copy the full SHA c7cef95View commit details -
Configuration menu - View commit details
-
Copy full SHA for 51fb298 - Browse repository at this point
Copy the full SHA 51fb298View commit details -
Configuration menu - View commit details
-
Copy full SHA for ecc2ada - Browse repository at this point
Copy the full SHA ecc2adaView commit details -
Configuration menu - View commit details
-
Copy full SHA for 5c9d60c - Browse repository at this point
Copy the full SHA 5c9d60cView commit details -
Introduce owning_ptr<T>; use it for JPEG2KEncode and JPEG2KDecode.
owning_ptr<T> adapts std::unique_ptr<T> to be a better drop-in replacement for a legacy class that formerly stored plain T* data members, and explicitly destroyed them using domain-specific destructor functions. Directly substituting std::unique_ptr into JPEG2KEncode and JPEG2KDecode was cumbersome because every such pointer declaration required a redundant template parameter describing the deleter function passed into its constructor. Moreover, it required lots of little syntax tweaks: changing every assignment to a reset() call, changing every reference to a get() call. Using owning_ptr<T> allows us to leave the code more or less as it was before, save that assignment and destruction automatically handle the previous referenced T instance.
Configuration menu - View commit details
-
Copy full SHA for 1c78829 - Browse repository at this point
Copy the full SHA 1c78829View commit details -
Configuration menu - View commit details
-
Copy full SHA for cf2f482 - Browse repository at this point
Copy the full SHA cf2f482View commit details -
Merge pull request #2714 from secondlife/nat/xcode-16
Clean up llpointer.h per previous discussions.
Configuration menu - View commit details
-
Copy full SHA for 71e89d6 - Browse repository at this point
Copy the full SHA 71e89d6View commit details