[pypy-commit] pypy default: Shut off a C compiler warning.
arigo
noreply at buildbot.pypy.org
Wed Apr 25 12:22:00 CEST 2012
Author: Armin Rigo <arigo at tunes.org>
Branch:
Changeset: r54743:a67352890558
Date: 2012-04-25 11:41 +0200
http://bitbucket.org/pypy/pypy/changeset/a67352890558/
Log: Shut off a C compiler warning.
diff --git a/pypy/translator/c/src/cjkcodecs/cjkcodecs.h b/pypy/translator/c/src/cjkcodecs/cjkcodecs.h
--- a/pypy/translator/c/src/cjkcodecs/cjkcodecs.h
+++ b/pypy/translator/c/src/cjkcodecs/cjkcodecs.h
@@ -210,15 +210,15 @@
#define BEGIN_CODECS_LIST /* empty */
#define _CODEC(name) \
- static const MultibyteCodec _pypy_cjkcodec_##name; \
- const MultibyteCodec *pypy_cjkcodec_##name(void) { \
+ static MultibyteCodec _pypy_cjkcodec_##name; \
+ MultibyteCodec *pypy_cjkcodec_##name(void) { \
if (_pypy_cjkcodec_##name.codecinit != NULL) { \
int r = _pypy_cjkcodec_##name.codecinit(_pypy_cjkcodec_##name.config); \
assert(r == 0); \
} \
return &_pypy_cjkcodec_##name; \
} \
- static const MultibyteCodec _pypy_cjkcodec_##name
+ static MultibyteCodec _pypy_cjkcodec_##name
#define _STATEFUL_METHODS(enc) \
enc##_encode, \
enc##_encode_init, \
diff --git a/pypy/translator/c/src/cjkcodecs/multibytecodec.h b/pypy/translator/c/src/cjkcodecs/multibytecodec.h
--- a/pypy/translator/c/src/cjkcodecs/multibytecodec.h
+++ b/pypy/translator/c/src/cjkcodecs/multibytecodec.h
@@ -131,7 +131,7 @@
/* list of codecs defined in the .c files */
#define DEFINE_CODEC(name) \
- const MultibyteCodec *pypy_cjkcodec_##name(void);
+ MultibyteCodec *pypy_cjkcodec_##name(void);
// _codecs_cn
DEFINE_CODEC(gb2312)
More information about the pypy-commit
mailing list