diff --git a/NEWS b/NEWS
index 9135184a..d246de8e 100644
--- a/NEWS
+++ b/NEWS
@@ -74,6 +74,11 @@ GNU Bison NEWS
      input: '0' | exp
                   ^^^
 
+*** Generated parsers can be compiled with -fno-exceptions (lalr1.cc)
+
+  When compiled with GCC and -fno-exceptions, the generated parsers disable
+  try/catch clauses.
+
 ** Bug fixes
 
 *** GLR: Predicates support broken by #line directives
diff --git a/data/lalr1.cc b/data/lalr1.cc
index 053875de..637a92cf 100644
--- a/data/lalr1.cc
+++ b/data/lalr1.cc
@@ -424,6 +424,15 @@ m4_if(b4_prefix, [yy], [],
 # endif
 #endif
 
+// Whether we are compiled with exception support.
+#ifndef YY_EXCEPTIONS
+# if defined __GNUC__ && !defined __EXCEPTIONS
+#  define YY_EXCEPTIONS 0
+# else
+#  define YY_EXCEPTIONS 1
+# endif
+#endif
+
 ]b4_locations_if([dnl
 [#define YYRHSLOC(Rhs, K) ((Rhs)[K].location)
 ]b4_yylloc_default_define])[
@@ -717,9 +726,11 @@ m4_if(b4_prefix, [yy], [],
     /// The return value of parse ().
     int yyresult;
 
+#if YY_EXCEPTIONS
     // FIXME: This shoud be completely indented.  It is not yet to
     // avoid gratuitous conflicts when merging into the master branch.
     try
+#endif // YY_EXCEPTIONS
       {
     YYCDEBUG << "Starting parse\n";
 
@@ -758,17 +769,21 @@ b4_dollar_popdef])[]dnl
     if (yyla.empty ())
       {
         YYCDEBUG << "Reading a token: ";
+#if YY_EXCEPTIONS
         try
+#endif // YY_EXCEPTIONS
           {]b4_token_ctor_if([[
             symbol_type yylookahead (]b4_lex[);
             yyla.move (yylookahead);]], [[
             yyla.type = yytranslate_ (]b4_lex[);]])[
           }
+#if YY_EXCEPTIONS
         catch (const syntax_error& yyexc)
           {
             error (yyexc);
             goto yyerrlab1;
           }
+#endif // YY_EXCEPTIONS
       }
     YY_SYMBOL_PRINT ("Next token is", yyla);
 
@@ -838,7 +853,9 @@ b4_dollar_popdef])[]dnl
 
       // Perform the reduction.
       YY_REDUCE_PRINT (yyn);
+#if YY_EXCEPTIONS
       try
+#endif // YY_EXCEPTIONS
         {
           switch (yyn)
             {
@@ -847,11 +864,13 @@ b4_dollar_popdef])[]dnl
               break;
             }
         }
+#if YY_EXCEPTIONS
       catch (const syntax_error& yyexc)
         {
           error (yyexc);
           YYERROR;
         }
+#endif // YY_EXCEPTIONS
       YY_SYMBOL_PRINT ("-> $$ =", yylhs);
       yypop_ (yylen);
       yylen = 0;
@@ -976,6 +995,7 @@ b4_dollar_popdef])[]dnl
 
     return yyresult;
   }
+#if YY_EXCEPTIONS
     catch (...)
       {
         YYCDEBUG << "Exception caught: cleaning lookahead and stack\n";
@@ -991,6 +1011,7 @@ b4_dollar_popdef])[]dnl
           }
         throw;
       }
+#endif // YY_EXCEPTIONS
   }
 
   void
