When I write this:
```
datatype One = One
predicate Crash() {
var One := One; true
}
```
A null pointer exception occurs in the Dafny process. Dafny says:
```
Suspicious state from syntax checker dafny: Checker dafny returned non-zero exit code 5, but no errors from output:
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.Dafny.CasePattern.AssembleExpr(List`1 dtvTypeArgs) in c:\dafny-public\Source\Dafny\DafnyAst.cs:line 7649
at Microsoft.Dafny.Resolver.ResolveCasePattern(CasePattern pat, Type sourceType, ICodeContext context) in c:\dafny-public\Source\Dafny\Resolver.cs:line 8852
at Microsoft.Dafny.Resolver.ResolveExpression(Expression expr, ResolveOpts opts) in c:\dafny-public\Source\Dafny\Resolver.cs:line 8134
at Microsoft.Dafny.Resolver.ResolveFunction(Function f) in c:\dafny-public\Source\Dafny\Resolver.cs:line 4470
at Microsoft.Dafny.Resolver.ResolveClassMemberBodies(ClassDecl cl) in c:\dafny-public\Source\Dafny\Resolver.cs:line 4058
at Microsoft.Dafny.Resolver.ResolveTopLevelDecls_Core(List`1 declarations, Graph`1 datatypeDependencies, Graph`1 codatatypeDependencies) in c:\dafny-public\Source\Dafny\Resolver.cs:line 1638
at Microsoft.Dafny.Resolver.ResolveModuleDefinition(ModuleDefinition m, ModuleSignature sig) in c:\dafny-public\Source\Dafny\Resolver.cs:line 725
at Microsoft.Dafny.Resolver.ResolveProgram(Program prog) in c:\dafny-public\Source\Dafny\Resolver.cs:line 326
at Microsoft.Dafny.Main.ParseCheck(IList`1 fileNames, String programName, ErrorReporter reporter, Program& program) in c:\dafny-public\Source\Dafny\DafnyMain.cs:line 70
at Microsoft.Dafny.DafnyDriver.ProcessFiles(IList`1 dafnyFileNames, ReadOnlyCollection`1 otherFileNames, ErrorReporter reporter, Boolean lookForSnapshots, String programId) in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 174
at Microsoft.Dafny.DafnyDriver.ThreadMain(String[] args) in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 106
at Microsoft.Dafny.DafnyDriver.<>c__DisplayClass1.<Main>b__0() in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 34
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()
Checker definition probably flawed.
```
Comments: Same as of bug 168
```
datatype One = One
predicate Crash() {
var One := One; true
}
```
A null pointer exception occurs in the Dafny process. Dafny says:
```
Suspicious state from syntax checker dafny: Checker dafny returned non-zero exit code 5, but no errors from output:
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object.
at Microsoft.Dafny.CasePattern.AssembleExpr(List`1 dtvTypeArgs) in c:\dafny-public\Source\Dafny\DafnyAst.cs:line 7649
at Microsoft.Dafny.Resolver.ResolveCasePattern(CasePattern pat, Type sourceType, ICodeContext context) in c:\dafny-public\Source\Dafny\Resolver.cs:line 8852
at Microsoft.Dafny.Resolver.ResolveExpression(Expression expr, ResolveOpts opts) in c:\dafny-public\Source\Dafny\Resolver.cs:line 8134
at Microsoft.Dafny.Resolver.ResolveFunction(Function f) in c:\dafny-public\Source\Dafny\Resolver.cs:line 4470
at Microsoft.Dafny.Resolver.ResolveClassMemberBodies(ClassDecl cl) in c:\dafny-public\Source\Dafny\Resolver.cs:line 4058
at Microsoft.Dafny.Resolver.ResolveTopLevelDecls_Core(List`1 declarations, Graph`1 datatypeDependencies, Graph`1 codatatypeDependencies) in c:\dafny-public\Source\Dafny\Resolver.cs:line 1638
at Microsoft.Dafny.Resolver.ResolveModuleDefinition(ModuleDefinition m, ModuleSignature sig) in c:\dafny-public\Source\Dafny\Resolver.cs:line 725
at Microsoft.Dafny.Resolver.ResolveProgram(Program prog) in c:\dafny-public\Source\Dafny\Resolver.cs:line 326
at Microsoft.Dafny.Main.ParseCheck(IList`1 fileNames, String programName, ErrorReporter reporter, Program& program) in c:\dafny-public\Source\Dafny\DafnyMain.cs:line 70
at Microsoft.Dafny.DafnyDriver.ProcessFiles(IList`1 dafnyFileNames, ReadOnlyCollection`1 otherFileNames, ErrorReporter reporter, Boolean lookForSnapshots, String programId) in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 174
at Microsoft.Dafny.DafnyDriver.ThreadMain(String[] args) in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 106
at Microsoft.Dafny.DafnyDriver.<>c__DisplayClass1.<Main>b__0() in c:\dafny-public\Source\DafnyDriver\DafnyDriver.cs:line 34
at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state)
at System.Threading.ThreadHelper.ThreadStart()
Checker definition probably flawed.
```
Comments: Same as of bug 168