Migrate mjtByte to mjtBool for boolean-valued fields.

PiperOrigin-RevId: 921408093
Change-Id: Icb00457836359779f0f72fc02d6a7c0dc9f6bd23
This commit is contained in:
Yuval Tassa
2026-05-26 05:35:15 -07:00
committed by Copybara-Service
parent 3cabb2eb8e
commit 393c1e4217
33 changed files with 242 additions and 224 deletions
+3 -3
View File
@@ -2024,13 +2024,13 @@ void mjs_setString(mjString* dest, const char* text) {
// Set specific entry in destination string vector.
mjtByte mjs_setInStringVec(mjStringVec* dest, int i, const char* text) {
mjtBool mjs_setInStringVec(mjStringVec* dest, int i, const char* text) {
if (dest->size() <= i) {
mju_error("Requested index in mjs_setInStringVec is out of bounds");
return 0;
return false;
}
dest->at(i) = std::string(text);
return 1;
return true;
}