You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$ crystal foo_object.cr
Module validation failed: Incorrect number of arguments passed to called function!
call void @"*Pointer(Void)@Object::to_s<String::Builder>:Nil"(i32 %obj, %"String::Builder"* %self), !dbg !183
(Exception)
from Crystal::CodeGenVisitor#finish:Nil
from Crystal::Compiler#codegen<Crystal::Program, Crystal::ASTNode+, Array(Crystal::Compiler::Source), String>:(Tuple(Array(Crystal::Compiler::CompilationUnit), Array(String)) | Nil)
from Crystal::Compiler#compile<Array(Crystal::Compiler::Source), String>:Crystal::Compiler::Result
from Crystal::Command#run_command<Bool>:Nil
from Crystal::Command#run:(Bool | Crystal::Compiler::Result | Nil)
from __crystal_main
from main
Error: you've found a bug in the Crystal compiler. Please open an issue, including source code that will allow us to reproduce the bug: https://github.com/crystal-lang/crystal/issues
This is on macOS Mojave 10.14.6
Output of crystal -v:
The actual conflict occurs within Spec::BeAExpectation#failure_message. Reduced:
libLibFootypeFoo=Pointer(Void)
endclassClass# corresponds to `#to_s(io)`,# called by `String::Builder#<<`,# called by `String.interpolation(*args : *T) forall T`,# called by `Spec::BeAExpectation#failure_message`deffoo(x)
x
endend
x =1LibFoo::Foo.foo(x)
Pointer(Void).foo(x)
But note that the linked spec should fail; LibAsdf::VoidPtr and Pointer(Void) are sibling types, so neither is a subtype of the other. (To make it pass, use alias instead of type.)
Reproduction:
https://gist.github.com/keidax/890f0a7195f64950effb3a302e879996
On macOS, I get this output:
This is on macOS Mojave 10.14.6
Output of
crystal -v
:The text was updated successfully, but these errors were encountered: