Could really do with a Delphi "WITH" equivalent

BlitzMax Forums/BlitzMax Programming/Could really do with a Delphi "WITH" equivalent

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

but now we are getting off topic here... even in a great oop design there are still times when a "with" or "alias" comes in handy.

I think this is a good example for "Alias"

setvalue(typex(mylist.myobject).getotherobject().getvaluex() * typex(mylist.myobject).getotherobject().getvaluey()

Alias a = "typex(mylist.myobject).getotherobject()"
setvalue(a.getvaluex() * a.getvaluey())
setothervalue(a.getvaluex() / a.getvaluey())
...


[edit]changed objectx() to typex()