From: Deborah G. <gol...@ap...> - 2005-05-27 22:05:09
|
My error, I had meant to use U_HIDE_DRAFT_API and U_SHOW_DRAFT_API. Deborah On May 27, 2005, at 2:19 PM, George Rhoten wrote: > icu...@li... wrote on 05/27/2005 12:03:19 > PM: > > >> This requires a change to udraft.h and everywhere it's invoked, as >> the test is currently: >> >> #ifdef U_HIDE_DRAFT_API >> >> which is true, even if the value of U_HIDE_DRAFT_API is 0. >> > > Hmm. Good point. > > >> >> Also, it's not possible to reliably reset the value of >> U_HIDE_DRAFT_API, as it's set in the middle of a header file. If I do >> this: >> >> #define U_HIDE_DRAFT_API 0 >> (includes) >> >> it doesn't work, because platform.h (which the user typically does >> not include directly) promptly resets U_HIDE_DRAFT_API back to 1. To >> work around this, you'd have to do: >> >> #include <unicode/platform.h> >> #define U_HIDE_DRAFT_API 0 >> (other includes) >> > > That wasn't what I was proposing. The platform.h has a guard around > the > definition. If it's already defined, it's not redefined, but this > is a > moot point. If people are already using defining U_HIDE_DRAFT_API > to hide > draft, there isn't much of a reason to change the usage. > > Actually I just noticed that currently U_HIDE_DRAFT_API is used > instead of > U_HIDE_DRAFT. Your original proposal used U_HIDE_DRAFT instead of > U_HIDE_DRAFT_API. So if you're proposing the following that would be > okay. > > in platform.h.in: > > #ifndef U_DEFAULT_HIDE_DRAFT > #define U_DEFAULT_HIDE_DRAFT @U_DEFAULT_HIDE_DRAFT@ > #endif > > (with the appropriate logic in configure) > > in utypes.h: > > #if U_DEFAULT_HIDE_DRAFT && !defined(U_SHOW_DRAFT) > #define U_HIDE_DRAFT_API 1 > #endif > > > > > > ------------------------------------------------------- > This SF.Net email is sponsored by Yahoo. > Introducing Yahoo! Search Developer Network - Create apps using Yahoo! > Search APIs Find out how you can build Yahoo! directly into your own > Applications - visit http://developer.yahoo.net/?fr=offad-ysdn-ostg- > q22005 > _______________________________________________ > icu-design mailing list > icu...@li... > https://lists.sourceforge.net/lists/listinfo/icu-design > |