Fix py-value.exp failure on Python 3
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.python / py-value.exp
index 89be6598cbfe2d5f50cb283bcf834ae024604db5..39b03850b6174254fe7659e05d7339e36d774862 100644 (file)
@@ -56,7 +56,11 @@ proc test_value_creation {} {
   }
 
   gdb_py_test_silent_cmd "python l = gdb.Value(0xffffffff12345678)" "create large unsigned 64-bit value" 1
-  gdb_test "python print long(l)" "18446744069720004216" "large unsigned 64-bit int conversion to python"
+  if { $gdb_py_is_py3k == 0 } {
+    gdb_test "python print long(l)" "18446744069720004216" "large unsigned 64-bit int conversion to python"
+  } else {
+    gdb_test "python print (int(l))" "18446744069720004216" "large unsigned 64-bit int conversion to python"
+  }
 
   gdb_py_test_silent_cmd "python f = gdb.Value (1.25)" "create double value" 1
   gdb_py_test_silent_cmd "python a = gdb.Value ('string test')" "create 8-bit string value" 1
This page took 0.024416 seconds and 4 git commands to generate.