Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
21
Task/Abstract-type/Lasso/abstract-type.lasso
Normal file
21
Task/Abstract-type/Lasso/abstract-type.lasso
Normal file
|
|
@ -0,0 +1,21 @@
|
|||
define abstract_trait => trait {
|
||||
require get(index::integer)
|
||||
|
||||
provide first() => .get(1)
|
||||
provide second() => .get(2)
|
||||
provide third() => .get(3)
|
||||
provide fourth() => .get(4)
|
||||
}
|
||||
|
||||
define my_type => type {
|
||||
parent array
|
||||
trait { import abstract_trait }
|
||||
|
||||
public onCreate(...) => ..onCreate(:#rest)
|
||||
}
|
||||
|
||||
local(test) = my_type('a','b','c','d','e')
|
||||
#test->first + "\n"
|
||||
#test->second + "\n"
|
||||
#test->third + "\n"
|
||||
#test->fourth + "\n"
|
||||
Loading…
Add table
Add a link
Reference in a new issue