It’s not so much that the pointer is not needed, but that it isn’t available so 
we have to figure out other ways to work around that fact when pointers would 
be more useful and allow you to write less brittle code.

Having to specify almost the same text for the name as for the expression, or 
reference the expression from the object script is brittle, and there’s no 
compiler help to make sure you got it all correct. 

What would be nice is the ability to have a pointer to the form control, and 
the ability to get/set the value using that reference (including updating the 
value in the bound expression). Sure, we can get by without it, just as we were 
able to get by without a built-in Form object and direct object property 
binding.

Jim Crate


> On Feb 5, 2020, at 3:43 AM, Keisuke Miyako via 4D_Tech <[email protected]> 
> wrote:
> 
> Hello,
> 
> Object get pointer(Object current)->
> 
> is synonymous to Self,
> 
> and likewise it will point to nothing if the current object is not bound to a 
> variable.
> 
> I think this is a strong sign that in object based design,
> pointers are very rarely needed, if at all,
> and that this kind of generic code (implicit dependency on data source)
> is probably a bad idea.
> 
> you can have some generic code to construct an object path, of course,
> but I think the variable factor should be a parameter or a value derived from 
> local code.

**********************************************************************
4D Internet Users Group (4D iNUG)
Archive:  http://lists.4d.com/archives.html
Options: https://lists.4d.com/mailman/options/4d_tech
Unsub:  mailto:[email protected]
**********************************************************************

Reply via email to