[Python-Dev] Oodles of warnings in cjkcodecs

Tim Peters tim.one at comcast.net
Thu Jan 22 14:20:15 EST 2004


Under MSVC 6, tons of new warnings are generated for these new files.  Then
all the new tests fail on Win98SE, with errors like:

    LookupError: unknown encoding: shift_jisx0213

New warnings:

multibytecodec.c
_cp932.c
C:\Code\python\Modules\cjkcodecs\_cp932.c(23) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_cp949.c
C:\Code\python\Modules\cjkcodecs\_cp949.c(21) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_cp950.c
C:\Code\python\Modules\cjkcodecs\_cp950.c(22) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_euc_jisx0213.c
_euc_jp.c
C:\Code\python\Modules\cjkcodecs\_euc_jisx0213.c(47) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_euc_jisx0213.c(54) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_euc_jisx0213.c(57) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_euc_jp.c(21) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_euc_kr.c
C:\Code\python\Modules\cjkcodecs\_euc_kr.c(20) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_gb18030.c
_gb2312.c
C:\Code\python\Modules\cjkcodecs\_gb2312.c(20) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_gbk.c
C:\Code\python\Modules\cjkcodecs\_gbk.c(22) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_hz.c
C:\Code\python\Modules\cjkcodecs\_hz.c(39) : warning C4244: '=' : conversion
from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_hz.c(42) : warning C4244: '=' : conversion
from 'unsigned short ' to 'unsigned char ', possible loss of data

_iso2022_jp.c
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\iso2022common.h(196) : warning C4018: '<' :
signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\_iso2022_jp.c(52) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp.c(64) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp.c(80) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp.c(104) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_iso2022_jp_1.c
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\iso2022common.h(196) : warning C4018: '<' :
signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_1.c(54) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_1.c(66) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_1.c(82) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_1.c(113) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_iso2022_jp_2.c
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\iso2022common.h(196) : warning C4018: '<' :
signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_2.c(60) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_2.c(72) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_2.c(88) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_2.c(143) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_iso2022_jp_3.c
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\iso2022common.h(196) : warning C4018: '<' :
signed/unsigned mismatch

_iso2022_jp_ext.c
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_3.c(84) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_3.c(91) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_3.c(94) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\iso2022common.h(196) : warning C4018: '<' :
signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_ext.c(52) : warning C4244: '='
: conversion from 'unsigned short ' to 'unsigned char ', possible loss of
data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_ext.c(64) : warning C4244: '='
: conversion from 'unsigned short ' to 'unsigned char ', possible loss of
data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_ext.c(80) : warning C4244: '='
: conversion from 'unsigned short ' to 'unsigned char ', possible loss of
data
C:\Code\python\Modules\cjkcodecs\_iso2022_jp_ext.c(113) : warning C4244: '='
: conversion from 'unsigned short ' to 'unsigned char ', possible loss of
data

_iso2022_kr.c
C:\Code\python\Modules\cjkcodecs\iso2022common.h(189) : warning C4018: '>='
: signed/unsigned mismatch
C:\Code\python\Modules\cjkcodecs\_iso2022_kr.c(46) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data
C:\Code\python\Modules\cjkcodecs\_iso2022_kr.c(50) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_johab.c
C:\Code\python\Modules\cjkcodecs\_johab.c(47) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_shift_jis.c
C:\Code\python\Modules\cjkcodecs\_shift_jis.c(35) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data

_shift_jisx0213.c
C:\Code\python\Modules\cjkcodecs\_shift_jisx0213.c(36) : warning C4244: '='
: conversion from 'unsigned short ' to 'unsigned char ', possible loss of
data

mapdata_ja_JP.c
C:\Code\python\Modules\cjkcodecs\_shift_jisx0213.c(51) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_shift_jisx0213.c(58) : warning C4761:
integral size mismatch in argument; conversion supplied
C:\Code\python\Modules\cjkcodecs\_shift_jisx0213.c(61) : warning C4761:
integral size mismatch in argument; conversion supplied
mapdata_ko_KR.c
mapdata_zh_CN.c
mapdata_zh_TW.c

_big5.c
C:\Code\python\Modules\cjkcodecs\_big5.c(21) : warning C4244: '=' :
conversion from 'unsigned short ' to 'unsigned char ', possible loss of data




More information about the Python-Dev mailing list