summaryrefslogblamecommitdiff
path: root/test/files/neg/catch-all.check
blob: a9cd0ba927ec5fb16d2d2ee7f6022d3e3e8eff5d (plain) (tree)
1
2
3
4
5
6
7
8
9
                                                                                                                                 

                                    
                                                                                                                                 

                                    
                                                                                                                                 

                                                                  
                  
catch-all.scala:2: error: This catches all Throwables. If this is really intended, use `case _: Throwable` to clear this warning.
  try { "warn" } catch { case _ => }
                              ^
catch-all.scala:4: error: This catches all Throwables. If this is really intended, use `case x: Throwable` to clear this warning.
  try { "warn" } catch { case x => }
                              ^
catch-all.scala:6: error: This catches all Throwables. If this is really intended, use `case x: Throwable` to clear this warning.
  try { "warn" } catch { case _: RuntimeException => ; case x => }
                                                            ^
three errors found