Boo

A stub is always created when a class implements an abstract generic method with at least one generic argument

Details

  • Type: Bug Bug
  • Status: Resolved Resolved
  • Priority: Major Major
  • Resolution: Fixed
  • Affects Version/s: 0.8.1
  • Fix Version/s: 0.8.2
  • Component/s: None
  • Labels:
    None
  • Testcase included:
    yes
  • Number of attachments :
    0

Description

cedric@laptop:~/dev/workspace/boo/boo$ cat tests/testcases/regression/BOO-1013-1.boo
"""
42
foo
"""

abstract class AbstractFoo:
        abstract def Bar[of T](x as T) as T:
                pass

class Foo(AbstractFoo):
        def Bar[of T](x as T) as T:
                print x
                return x

foo = Foo()
assert 42 == foo.Bar[of int](42)
assert "foo" == foo.Bar[of string]("foo")

cedric@laptop:~/dev/workspace/boo/boo$ booc tests/testcases/regression/BOO-1013-1.boo
Boo Compiler version 0.8.1.2932 (CLR v2.0.50727.42)
tests/testcases/regression/BOO-1013-1.boo(10,11): BCW0011: WARNING: Type 'Foo' does not provide an implementation for 'AbstractFoo.Bar`1(AbstractFoo.Bar`1.T)', a stub has been created.
1 warning(s).

Activity

Hide
Cedric Vivier added a comment -

fixed in rev. 2946

Show
Cedric Vivier added a comment - fixed in rev. 2946

People

Vote (0)
Watch (0)

Dates

  • Created:
    Updated:
    Resolved: