Forums
Search found 35 matches: mixin
Re: RFC for suggestion: setting access rights to added mixin
... (or struct), so they become protected and private members of what they are added to. There is currently no way to make a member private to the mixin. We can leave that as is or try to address it. As you use mixins, keep sharing whatever issues you run into.
- Wed Nov 07, 2012 11:17 am
- Forum: Discussion
- Topic: RFC for suggestion: setting access rights to added mixins
- Replies: 3
- Views: 13342
Re: support for namespace enclosed mixin?
Just for the record in case someone finds this thread, this problem was fixed some time ago and is covered by the test suite. I just didn't respond to this message.
- Wed Nov 07, 2012 10:36 am
- Forum: Discussion
- Topic: support for namespace enclosed mixin?
- Replies: 1
- Views: 8055
Re: Decorator idea
... cases. I'd prefer a specific keyword introduction syntax for it rather than an addition to is-names. We've already chosen that path with mixin syntax ( adds ) - having this doesnt preclude an inheritance clause as well ( ... inherits ... decorates .... ) - currently I see is-names as ...
- Wed Nov 07, 2012 5:40 am
- Forum: Discussion
- Topic: Decorator idea
- Replies: 12
- Views: 27186
Re: RFC for suggestion: setting access rights to added mixin
"is protected" This almost works: mixin A def one as int return 1 def two as int is protected return 2 class B adds A def foo trace .one trace .two class P def main b = B() b.foo b.one # b.two I had to comment out the last line ...
- Tue Nov 06, 2012 11:47 am
- Forum: Discussion
- Topic: RFC for suggestion: setting access rights to added mixins
- Replies: 3
- Views: 13342
RFC for suggestion: setting access rights to added mixins
Hi, I have a class, that adds a mixin. I would like to hide a few of the mixin public members/methods so as to only use them internally, but have them be invisible (private) to the outside consumer. (the hiding happens in the class, doesn't ...
- Tue Nov 06, 2012 12:55 am
- Forum: Discussion
- Topic: RFC for suggestion: setting access rights to added mixins
- Replies: 3
- Views: 13342
Re: mixins: problem with variables?
... thanks for the quick fix. That's enough to help me move forward. For the record, local variables still cause problems if within other blocks. e.g. mixin MyCode def hi myvar = 0 if myvar < 10 inner = 2 print "a [inner]" else print "b" mixin.cobra(3): warning: The value of variable ...
- Sun Nov 13, 2011 3:48 am
- Forum: Discussion
- Topic: mixins: problem with variables?
- Replies: 4
- Views: 10311
mixins: problem with variables?
Hi, I have started to look at mixins. What I am aiming to do is add some implemented methods and perhaps state to a couple of otherwise independent classes. I've hit a problem, which suggests it is not possible to define local variables ...
- Fri Nov 11, 2011 3:12 pm
- Forum: Discussion
- Topic: mixins: problem with variables?
- Replies: 4
- Views: 10311
Re: Mixins
A partial class is just a class that is split up into multiple files. A mixin can be mixed into many classes similar to an interface which can be implemented by many classes.
- Sat Jan 30, 2010 12:18 pm
- Forum: Discussion
- Topic: Mixins
- Replies: 12
- Views: 49252
Re: generic mixin
I missed the wiki page, sorry about that.
So I updated it to state theses limitations, I'm going to work arround theses in my code
So I updated it to state theses limitations, I'm going to work arround theses in my code
- Tue Nov 03, 2009 4:38 pm
- Forum: Discussion
- Topic: generic mixin
- Replies: 2
- Views: 11639
Re: generic mixin
As you've discovered, the mixin support is incomplete. Some of this is documented at the mix-in wiki page. Nevertheless, thanks for the reports.
I probably won't get to this soon as there are a number of small items and patches I'll attend to first.
I probably won't get to this soon as there are a number of small items and patches I'll attend to first.
- Mon Nov 02, 2009 10:15 pm
- Forum: Discussion
- Topic: generic mixin
- Replies: 2
- Views: 11639
- Search found 35 matches • Page 2 of 4 • 1, 2, 3, 4