diff options
author | Martin Odersky <odersky@gmail.com> | 2016-09-04 18:48:08 +0200 |
---|---|---|
committer | Martin Odersky <odersky@gmail.com> | 2016-10-02 16:11:21 +0200 |
commit | 7cce2d463a001f5f5660a391a71bddd2cde1a15f (patch) | |
tree | eb5160defdf9ce879d9c4892a9b30c942b31ae62 /src/dotty/tools/dotc/typer | |
parent | 9a48e7bc56979c5968149e6aabdae96d33681a60 (diff) | |
download | dotty-7cce2d463a001f5f5660a391a71bddd2cde1a15f.tar.gz dotty-7cce2d463a001f5f5660a391a71bddd2cde1a15f.tar.bz2 dotty-7cce2d463a001f5f5660a391a71bddd2cde1a15f.zip |
Harden Inliner.sourceFile
Diffstat (limited to 'src/dotty/tools/dotc/typer')
-rw-r--r-- | src/dotty/tools/dotc/typer/Inliner.scala | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/dotty/tools/dotc/typer/Inliner.scala b/src/dotty/tools/dotc/typer/Inliner.scala index 88d8b0de5..fbb847e9d 100644 --- a/src/dotty/tools/dotc/typer/Inliner.scala +++ b/src/dotty/tools/dotc/typer/Inliner.scala @@ -95,7 +95,7 @@ object Inliner { def sourceFile(call: Tree)(implicit ctx: Context) = { val file = call.symbol.sourceFile - if (file.exists) new SourceFile(file) else NoSource + if (file != null && file.exists) new SourceFile(file) else NoSource } } |