Data commit

This commit is contained in:
Ingy döt Net 2023-07-01 11:58:00 -04:00
parent 7387c8f97b
commit cb5bb5e222
199093 changed files with 3378972 additions and 0 deletions

View file

@ -0,0 +1,13 @@
coclass 'delegator'
operation=:3 :'thing__delegate ::thing y'
thing=: 'default implementation'"_
setDelegate=:3 :'delegate=:y' NB. result is the reference to our new delegate
delegate=:<'delegator'
coclass 'delegatee1'
coclass 'delegatee2'
thing=: 'delegate implementation'"_
NB. set context in case this script was used interactively, instead of being loaded
cocurrent 'base'

View file

@ -0,0 +1,15 @@
obj=:conew'delegator'
operation__obj''
default implementation
setDelegate__obj conew'delegatee1'
┌─┐
│4│
└─┘
operation__obj''
default implementation
setDelegate__obj conew'delegatee2'
┌─┐
│5│
└─┘
operation__obj''
delegate implementation