shard-spectator/spec
Michael Miller e05ef94ef5
Initial work on stub DSL - found bug in Crystal compiler
```
Module validation failed: Invalid bitcast
  %4 = bitcast i32* %3 to %"(Spectator::Arguments(T, NT) | Nil)", !dbg !16
 (Exception)
  from /crystal/src/int.cr:541:9 in 'finish'
  from /crystal/src/compiler/crystal/codegen/codegen.cr:71:7 in 'codegen'
  from /crystal/src/compiler/crystal/compiler.cr:173:16 in 'compile'
  from /crystal/src/compiler/crystal/command/spec.cr:98:14 in 'spec'
  from /crystal/src/hash.cr:901:11 in '__crystal_main'
  from /crystal/src/crystal/main.cr:115:5 in 'main'
  from src/env/__libc_start_main.c:94:2 in 'libc_start_main_stage2'
Error: you've found a bug in the Crystal compiler. ...
```

I haven't been able to reproduce this in a simplified form.

Passing the `constraint` argument in NullStub#and_return to ValueStub.new triggers the bug.
Removing the `constraint` argument fixes the issue.
2022-03-31 22:49:45 -06:00
..
docs Remove or skip mock, double, and stub tests 2022-03-19 17:20:15 -06:00
features Support multiple block arguments in sample block 2022-01-11 15:53:53 -07:00
helpers Spelling 2022-01-10 21:10:36 -07:00
issues Works now due to lazy doubles 2022-03-30 19:13:14 -06:00
matchers Remove or skip mock, double, and stub tests 2022-03-19 17:20:15 -06:00
rspec Formatting 2022-01-07 17:27:25 -07:00
spectator Initial work on stub DSL - found bug in Crystal compiler 2022-03-31 22:49:45 -06:00
runtime_example_spec.cr Mark slow compilation tests 2021-08-18 15:57:39 -06:00
spec_helper.cr Initial work on Double 2022-03-03 22:10:09 -07:00