Saaa schrieb:
> I'd like the following:
>
> texture.bind() //class texture, method bind.
> {
> ..
> } //here texture.unbind would automatically be run.
>
> Is this possible?
>
>
>
>
void bind( Texture t, void delegate() dg ){
t.bind();
dg();
t.unbind();
}
bind( texture, {
...
});