clean up tyConst remnants

This commit is contained in:
Jacek Sieka 2016-10-24 23:19:46 +08:00
commit b3de34548d
10 changed files with 32 additions and 37 deletions

View file

@ -151,7 +151,7 @@ proc mapType(typ: PType): TJSTypeKind =
of tyPointer:
# treat a tyPointer like a typed pointer to an array of bytes
result = etyBaseIndex
of tyRange, tyDistinct, tyOrdinal, tyConst, tyMutable, tyProxy:
of tyRange, tyDistinct, tyOrdinal, tyMutable, tyProxy:
result = mapType(t.sons[0])
of tyInt..tyInt64, tyUInt..tyUInt64, tyEnum, tyChar: result = etyInt
of tyBool: result = etyBool
@ -170,7 +170,7 @@ proc mapType(typ: PType): TJSTypeKind =
else: result = etyNone
of tyProc: result = etyProc
of tyCString: result = etyString
of tyUnused, tyUnused0: internalError("mapType")
of tyUnused, tyUnused0, tyUnused1: internalError("mapType")
proc mapType(p: PProc; typ: PType): TJSTypeKind =
if p.target == targetPHP: result = etyObject