}
return 0.0
}
+
+# Return the version of the Rust compiler.
+gdb_caching_proc rust_compiler_version {
+ set rustc [find_rustc]
+ if {$rustc == ""} {
+ verbose "could not find rustc"
+ } else {
+ set output [lindex [remote_exec host "$rustc --version --verbose"] 1]
+ foreach line [split $output \n] {
+ if {[regexp "rustc (\[0-9.\]+) .*\$" $output ignore version]} {
+ return $version
+ }
+ }
+ verbose "could not match rustc version output: $output"
+ }
+ return 0.0
+}