summaryrefslogtreecommitdiff
path: root/BCT/BytecodeTranslator/TranslationHelper.cs
diff options
context:
space:
mode:
Diffstat (limited to 'BCT/BytecodeTranslator/TranslationHelper.cs')
-rw-r--r--BCT/BytecodeTranslator/TranslationHelper.cs7
1 files changed, 5 insertions, 2 deletions
diff --git a/BCT/BytecodeTranslator/TranslationHelper.cs b/BCT/BytecodeTranslator/TranslationHelper.cs
index 756f127f..d421c573 100644
--- a/BCT/BytecodeTranslator/TranslationHelper.cs
+++ b/BCT/BytecodeTranslator/TranslationHelper.cs
@@ -40,7 +40,7 @@ namespace BytecodeTranslator {
this.underlyingParameter = parameterDefinition;
- Bpl.Type ptype = Bpl.Type.Int;
+ Bpl.Type ptype = TranslationHelper.CciTypeToBoogie(parameterDefinition.Type);
var parameterToken = parameterDefinition.Token();
var typeToken = parameterDefinition.Type.Token();
@@ -86,7 +86,10 @@ namespace BytecodeTranslator {
#region Temp Stuff that must be replaced as soon as there is real code to deal with this
public static Bpl.Type CciTypeToBoogie(ITypeReference type) {
- return Bpl.Type.Int;
+ if (TypeHelper.IsPrimitiveInteger(type))
+ return Bpl.Type.Int;
+ else
+ return Bpl.Type.Int; // BUG! This is where we need to return "ref" for a reference type
}
public static Bpl.Variable TempHeapVar() {