Index: runtime/vm/compiler.cc |
diff --git a/runtime/vm/compiler.cc b/runtime/vm/compiler.cc |
index 3293a188cf42c97fe08de86cfd1476c581f46667..4c1e6d3abc326892f45c144c1b2da06d2e6d9ea8 100644 |
--- a/runtime/vm/compiler.cc |
+++ b/runtime/vm/compiler.cc |
@@ -165,6 +165,10 @@ DEFINE_RUNTIME_ENTRY(CompileFunction, 1) { |
const Error& error = |
Error::Handle(Compiler::CompileFunction(thread, function)); |
if (!error.IsNull()) { |
+ if (error.IsLanguageError()) { |
+ Exceptions::ThrowCompileTimeError(LanguageError::Cast(error)); |
+ UNREACHABLE(); |
+ } |
Exceptions::PropagateError(error); |
} |
} |