From: barbieri Date: Sat, 27 Feb 2010 14:51:52 +0000 (+0000) Subject: ouch, SPANK SPANK SPANK... me :-( wrong function attributes. X-Git-Tag: 2.0_alpha~70^2~602 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=6ada20e08ab7cd76f99ea18de9f4567da86c3145;p=framework%2Fuifw%2Feina.git ouch, SPANK SPANK SPANK... me :-( wrong function attributes. I forgot that EINA_CONST refer to the pointer itself, not to its contents, as such the pointer did not changed, so gcc was optimizing subsequent fetches of the value. There should be another optimization to check for this... but then I guess it's just c++ git-svn-id: svn+ssh://svn.enlightenment.org/var/svn/e/trunk/eina@46580 7cbeb6ba-43b4-40fd-8cce-4c39aea84d33 --- diff --git a/src/include/eina_strbuf.h b/src/include/eina_strbuf.h index a529ec1..0d65f65 100644 --- a/src/include/eina_strbuf.h +++ b/src/include/eina_strbuf.h @@ -31,9 +31,9 @@ EAPI Eina_Bool eina_strbuf_insert_char(Eina_Strbuf *buf, char c, size_t pos) EIN EAPI Eina_Bool eina_strbuf_remove(Eina_Strbuf *buf, size_t start, size_t end) EINA_ARG_NONNULL(1); -EAPI const char *eina_strbuf_string_get(const Eina_Strbuf *buf) EINA_CONST EINA_ARG_NONNULL(1); +EAPI const char *eina_strbuf_string_get(const Eina_Strbuf *buf) EINA_ARG_NONNULL(1); EAPI char *eina_strbuf_string_steal(Eina_Strbuf *buf) EINA_MALLOC EINA_WARN_UNUSED_RESULT EINA_ARG_NONNULL(1); -EAPI size_t eina_strbuf_length_get(const Eina_Strbuf *buf) EINA_CONST EINA_ARG_NONNULL(1); +EAPI size_t eina_strbuf_length_get(const Eina_Strbuf *buf) EINA_ARG_NONNULL(1); EAPI Eina_Bool eina_strbuf_replace(Eina_Strbuf *buf, const char *str, const char *with, unsigned int n) EINA_ARG_NONNULL(1, 2, 3); #define eina_strbuf_replace_first(buf, str, with) \ eina_strbuf_replace(buf, str, with, 1)