reduce cost of unsigned type conversion

This commit is contained in:
Zachary Snow 2025-02-17 19:25:39 -05:00
parent 4ec99fcffd
commit 8cc828c77f
2 changed files with 3 additions and 2 deletions

View File

@ -74,6 +74,7 @@ finalPhases _ =
, Convert.EmptyArgs.convert
, Convert.FuncRet.convert
, Convert.TFBlock.convert
, Convert.Unsigned.convert
, Convert.StringType.convert
]
@ -96,7 +97,6 @@ mainPhases tops selectExclude =
, Convert.Struct.convert
, Convert.Typedef.convert
, Convert.UnpackedArray.convert
, Convert.Unsigned.convert
, Convert.Wildcard.convert
, Convert.Enum.convert
, Convert.StringParam.convert

View File

@ -18,7 +18,8 @@ convert =
map $
traverseDescriptions $
traverseModuleItems $
traverseTypes $ traverseNestedTypes convertType
-- doesn't need to visit nested types, as they have been elaborated
traverseTypes convertType
convertType :: Type -> Type
convertType (Implicit Unsigned rs) = Implicit Unspecified rs