Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/corert.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormikedn <onemihaid@hotmail.com>2017-01-22 19:40:28 +0300
committerJan Kotas <jkotas@microsoft.com>2017-01-22 19:40:28 +0300
commit8811353cbb66d10f456710c7388ffd3f98f48788 (patch)
treee5586a44f0090842ceac990d54bf09d20ec5023e
parent55aec2695031ea3b172bb4cfb1e60c2cdbd70c27 (diff)
Add missing cast to intptr_t (#2564)
ldobj import casts the stack value to the token type but then wants to store the result as intptr_t again so another cast is needed.
-rw-r--r--src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs b/src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs
index 03133ce93..3c6f7e8ef 100644
--- a/src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs
+++ b/src/ILCompiler.Compiler/src/CppCodeGen/ILToCppImporter.cs
@@ -1944,6 +1944,7 @@ namespace Internal.IL
PushTemp(GetStackValueKind(type), type);
+ AppendCastIfNecessary(GetStackValueKind(type), type);
Append("*(");
Append(_writer.GetCppSignatureTypeName(type));
Append("*)");