[ nice-Bugs-1087831 ] AssertionError in type system
"SourceForge.net" <[email protected]> Sun, 19 Dec 2004 13:55:47 -0800
| Newsgroups | gmane.comp.lang.nice.devel |
|---|---|
| Message-ID | <[email protected]> |
Bugs item #1087831, was opened at 2004-12-19 08:49
Message generated for change (Comment added) made by bonniot
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1087831&group_id=12788
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Luc Perrin (leblin)
Assigned to: Nobody/Anonymous (nobody)
Summary: AssertionError in type system
Initial Comment:
class A {}
void foo()
{
let a = cast( new A[1] );
assert a != null;
}
The assert call above causes the following error in the
compiler:
An exception has occured in the compiler
Please fill-in a bug report at the following webpage:
http://sourceforge.net/tracker/?func=add&group_id=12788&atid=112788
Stack trace:
Exception in thread "main" bossa.util.InternalError:
panic: assertion failed:
at bossa.util.Internal.error(Internal.java:86)
at mlsub.typing.lowlevel.S.panic(S.java:79)
at mlsub.typing.lowlevel.S.assume(S.java:101)
at mlsub.typing.lowlevel.S.assume(S.java:97)
at
mlsub.typing.lowlevel.DomainVector.reduce(DomainVector.java:48)
at
mlsub.typing.lowlevel.K0.reduceDomain(K0.java:838)
at mlsub.typing.lowlevel.K0.leq0(K0.java:692)
at mlsub.typing.lowlevel.K0.leq(K0.java:648)
at
mlsub.typing.lowlevel.Engine$Constraint.leq(Engine.java:928)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:265)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:232)
at mlsub.typing.Variance.leq(Variance.java:198)
at mlsub.typing.Variance.leq(Variance.java:190)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:265)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:232)
at
mlsub.typing.NullnessKind.leq(NullnessKind.java:90)
at
mlsub.typing.NullnessKind.leq(NullnessKind.java:81)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:265)
at
mlsub.typing.lowlevel.Engine.leq(Engine.java:232)
at mlsub.typing.Typing.leq(Typing.java:355)
at mlsub.typing.Typing.in(Typing.java:521)
at mlsub.typing.Typing.in(Typing.java:541)
at bossa.syntax.fun.getType(block.nice:148)
at bossa.syntax.dispatch.getType(dispatch.nice)
at bossa.syntax.fun.wellTyped(call.nice:284)
at bossa.syntax.dispatch.wellTyped(dispatch.nice)
at
bossa.syntax.fun.resolveOverloading(overloadedsymbol.nice:130)
at
bossa.syntax.dispatch.resolveOverloading(dispatch.nice)
at
bossa.syntax.fun.resolveOverloading(call.nice:54)
at
bossa.syntax.CallExp.resolveOverloading(call.nice)
at bossa.syntax.fun.computeType(call.nice:69)
at bossa.syntax.CallExp.computeType(call.nice)
at
bossa.syntax.Expression.getType(Expression.java:156)
at bossa.syntax.fun.typecheck(typecheck.nice:230)
at bossa.syntax.dispatch.typecheck(dispatch.nice)
at
bossa.syntax.fun.typecheckArgs(typecheck.nice:112)
at
bossa.syntax.dispatch.typecheckArgs(dispatch.nice)
at bossa.syntax.fun.typecheck(typecheck.nice:209)
at bossa.syntax.dispatch.typecheck(dispatch.nice)
at bossa.syntax.fun.typecheck(typecheck.nice:832)
at bossa.syntax.dispatch.typecheck(dispatch.nice)
at bossa.syntax.fun.lambda13(typecheck.nice:746)
at bossa.syntax.fun.apply1(fun.nice)
at
gnu.expr.ModuleMethod.apply1(ModuleMethod.java:89)
at nice.lang.fun.foreach(collections.nice:141)
at nice.lang.dispatch.foreach(dispatch.nice)
at bossa.syntax.fun.typecheck(typecheck.nice:744)
at bossa.syntax.dispatch.typecheck(dispatch.nice)
at bossa.syntax.fun.lambda13(typecheck.nice:746)
at bossa.syntax.fun.apply1(fun.nice)
at
gnu.expr.ModuleMethod.apply1(ModuleMethod.java:89)
at nice.lang.fun.foreach(collections.nice:141)
at nice.lang.dispatch.foreach(dispatch.nice)
at bossa.syntax.fun.typecheck(typecheck.nice:744)
at bossa.syntax.dispatch.typecheck(dispatch.nice)
at
bossa.syntax.DefaultMethodImplementation.innerTypecheck(DefaultMethodImplementation.java:97)
at
bossa.syntax.NiceMethod$WithDefault.innerTypecheck(NiceMethod.java:390)
at
bossa.syntax.MethodDeclaration.typecheck(MethodDeclaration.java:229)
at bossa.syntax.Node.doTypecheck(Node.java:302)
at bossa.syntax.Node.doTypecheck(Node.java:307)
at bossa.syntax.Node.doTypecheck(Node.java:307)
at bossa.syntax.AST.typechecking(AST.java:188)
at
bossa.modules.Package.typecheck(Package.java:327)
at mlsub.compilation.fun.lambda24(make.nice:29)
at mlsub.compilation.fun.apply1(fun.nice)
at
gnu.expr.ModuleMethod.apply1(ModuleMethod.java:89)
at nice.lang.fun.foreach(collections.nice:141)
at nice.lang.dispatch.foreach(dispatch.nice)
at
mlsub.compilation.fun.compileComponent(make.nice:29)
at
mlsub.compilation.dispatch.compileComponent(dispatch.nice)
at
mlsub.compilation.fun$make.lambda23(make.nice:45)
at mlsub.compilation.fun$make.apply1(fun.nice)
at
gnu.expr.ModuleMethod.apply1(ModuleMethod.java:89)
at nice.lang.fun.foreach(collections.nice:141)
at nice.lang.dispatch.foreach(dispatch.nice)
at mlsub.compilation.fun.make(make.nice:44)
at mlsub.compilation.dispatch.make(dispatch.nice)
at
nice.tools.compiler.fun.compile(interface.nice:40)
at
bossa.modules.Compilation.compile(Compilation.nice)
at
nice.tools.compiler.console.fun.compile(main.nice:165)
at
nice.tools.compiler.console.dispatch.compile(dispatch.nice)
at
nice.tools.compiler.console.fun.main(main.nice:181)
at
nice.tools.compiler.console.dispatch.main(dispatch.nice)
----------------------------------------------------------------------
>Comment By: Daniel Bonniot (bonniot)
Date: 2004-12-19 22:55
Message:
Logged In: YES
user_id=88952
This is most likely related to polymorphic type inference.
You should be able to get the code to work simply by
specifying the type of the variable.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=112788&aid=1087831&group_id=12788
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://productguide.itmanagersjournal.com/