git.iko.soy/rowtype-yoga/purescript-native
on golang help sign in
C++: get rid of unnecessary explicit unthunk on main() call
6a7b3d7Andy Arvanitis
src/Language/PureScript/CodeGen/Cpp/File.hs+1−3
@@ -173,8 +173,6 @@ nativeMain = CppFunction "main"
173 []
173 []
174 (CppBlock [ CppUseNamespace "Main"
174 (CppBlock [ CppUseNamespace "Main"
175 , CppApp (CppVar "INITIALIZE_GC") []
175 , CppApp (CppVar "INITIALIZE_GC") []
176− , CppApp (CppApp (CppAccessor (CppVar "main") (CppVar "Main"))
176+ , CppApp (CppAccessor (CppVar "main") (CppVar "Main")) []
177− [CppVar unthunkMarkerValue])
178− []
179 , CppReturn (CppNumericLiteral (Left 0))
177 , CppReturn (CppNumericLiteral (Left 0))
180 ])
178 ])
src/Language/PureScript/CodeGen/Cpp/Types.hs−3
@@ -121,8 +121,5 @@ arrayType = CppPrimitive "any::array"
121thunkMarkerType :: CppType
121thunkMarkerType :: CppType
122thunkMarkerType = CppPrimitive "any::as_thunk"
122thunkMarkerType = CppPrimitive "any::as_thunk"
123
123
124−unthunkMarkerValue :: String
125−unthunkMarkerValue = "any::unthunk"
126−
127ctorKey :: String
124ctorKey :: String
128ctorKey = "constructor"
125ctorKey = "constructor"