Automatic date update in version.in
[deliverable/binutils-gdb.git] / gdb / testsuite / gdb.ada / formatted_ref.exp
index a0009106d65cc44c58628f67c8ec8e6eb6b4dd5b..8376513a784ba646dc4abe5ba282d4ff11ca67fa 100644 (file)
@@ -1,4 +1,4 @@
-# Copyright 2007-2019 Free Software Foundation, Inc.
+# Copyright 2007-2020 Free Software Foundation, Inc.
 #
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -67,14 +67,16 @@ proc test_p_x { var val addr } {
 proc test_p_x_addr { var addr } {
     global gdb_prompt
 
-    set test "print/x $var'access"
-    gdb_test_multiple $test $test {
-        -re "\\$\[0-9\]+ = $addr.*$gdb_prompt $" {
-           pass $test
-       } 
-       -re "\\$\[0-9\]+ = 0x\[a-f0-9+\]+.*$gdb_prompt $" {
-            fail "$test (prints unexpected address)"
-        }
+    foreach attr {access unchecked_access unrestricted_access} {
+       set test "print/x $var'$attr"
+       gdb_test_multiple $test $test {
+           -re "\\$\[0-9\]+ = $addr.*$gdb_prompt $" {
+               pass $test
+           }
+           -re "\\$\[0-9\]+ = 0x\[a-f0-9+\]+.*$gdb_prompt $" {
+               fail "$test (prints unexpected address)"
+           }
+       }
     }
     return 0
 }
This page took 0.023887 seconds and 4 git commands to generate.