ninja: Entering directory `out/Static' [1/809] compile ../../third_party/externals/icu/source/common/appendable.cpp FAILED: obj/third_party/externals/icu/source/common/libicu.appendable.o c++ -MD -MF obj/third_party/externals/icu/source/common/libicu.appendable.o.d -DU_COMMON_IMPLEMENTATION -DU_STATIC_IMPLEMENTATION -DU_ENABLE_DYLOAD=0 -DU_I18N_IMPLEMENTATION -D_XOPEN_SOURCE=0 -DSK_TRIVIAL_ABI=\[\[clang::trivial_abi\]\] -DU_USING_ICU_NAMESPACE=0 -DU_DISABLE_RENAMING -DSK_USING_THIRD_PARTY_ICU -w -Wno-attributes -ffp-contract=off -fstrict-aliasing -fPIC -fvisibility=hidden -g -gdwarf-4 -I/usr/local/include -I/usr/local/include/harfbuzz -I/usr/local/include/freetype2 -O3 -fdata-sections -ffunction-sections -isystem /usr/home/hodong/skia/third_party/externals/icu/source/common -isystem /usr/home/hodong/skia/third_party/externals/icu/source/i18n -isystem /usr/home/hodong/skia/third_party/icu -std=c++17 -fvisibility-inlines-hidden -fno-exceptions -fno-rtti -frtti -c ../../third_party/externals/icu/source/common/appendable.cpp -o obj/third_party/externals/icu/source/common/libicu.appendable.o ../../third_party/externals/icu/source/common/appendable.cpp:40:24: error: use of undeclared identifier 'FALSE' return FALSE; ^ ../../third_party/externals/icu/source/common/appendable.cpp:47:24: error: use of undeclared identifier 'FALSE' return FALSE; ^ ../../third_party/externals/icu/source/common/appendable.cpp:51:12: error: use of undeclared identifier 'TRUE' return TRUE; ^ ../../third_party/externals/icu/source/common/appendable.cpp:56:12: error: use of undeclared identifier 'TRUE' return TRUE; ^

이렇게 에러가 났는데 소스코드를 보니,

UBool Appendable::appendString(const UChar *s, int32_t length) { if(length<0) { UChar c; while((c=*s++)!=0) { if(!appendCodeUnit(c)) { return FALSE; } } } else if(length>0) { const UChar *limit=s+length; do { if(!appendCodeUnit(*s++)) { return FALSE; } } while(s<limit); } return TRUE; }

소스코드에는 이렇게 되어 있지.

UBool 이 뭔지 알아야 됨.

매뉴얼보면

https://unicode-org.github.io/icu/userguide/dev/codingguidelines.html

Coding GuidelinesICU is a mature, widely used set of C/C++ and Java libraries providing Unicode and Globalization support for software applications. The ICU User Guide provides documentation on how to use ICU.unicode-org.github.io


친절하게 잘 나옴

The language built-in type bool and constants true and false may be used internally, for local variables and parameters of internal functions. The ICU type UBool must be used in public APIs and in the definition of any persistent data structures. UBool is guaranteed to be one byte in size and signed; bool is not. Except: Starting with ICU 70 (2021q4), operator==() and operator!=() must return bool, not UBool, because of a change in C++20, see ICU-20973.


TRUE, FALSE 및 operator 부분에서 에러 났음.


https://unicode-org.github.io/icu-docs/apidoc/dev/icu4c/umachine_8h.html

ICU 73.1: umachine.h File ReferenceICU 73.1: umachine.h File Referenceunicode-org.github.io


여기 보면.

typedef int8_t UBool

이렇게 친절히 나오네.

저거를 bool 타입으로 바꿔도 무방함.


 C++ 폭도들 이런 글엔 댓글 안 달더라 ㅎㅎ