diff options
author | Philip Herron <herron.philip@googlemail.com> | 2020-05-20 17:56:00 +0100 |
---|---|---|
committer | Philip Herron <philip.herron@embecosm.com> | 2020-11-28 21:13:14 +0000 |
commit | 484a4c96a291afbc7df2e077d734459c10387891 (patch) | |
tree | 8f857aff01575e87057716ad77c9df6a62c8a286 /gcc | |
parent | cb00023bcb0bc71ae877626400e6039ae5876920 (diff) | |
download | gcc-484a4c96a291afbc7df2e077d734459c10387891.zip gcc-484a4c96a291afbc7df2e077d734459c10387891.tar.gz gcc-484a4c96a291afbc7df2e077d734459c10387891.tar.bz2 |
Don't continue to compilation to GIMPLE phase if we saw errors
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/rust/rust-session-manager.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gcc/rust/rust-session-manager.cc b/gcc/rust/rust-session-manager.cc index f840eb8..4308ae3 100644 --- a/gcc/rust/rust-session-manager.cc +++ b/gcc/rust/rust-session-manager.cc @@ -1,5 +1,6 @@ #include "rust-session-manager.h" +#include "rust-diagnostics.h" #include "diagnostic.h" #include "input.h" @@ -495,6 +496,9 @@ Session::parse_file (const char *filename) return; } + if (saw_errors ()) + return; + // do compile Compile::Compilation::Compile (parsed_crate, backend); } |