IWETHEY v. 0.3.0 | TODO
1,095 registered users | 0 active users | 0 LpH | Statistics
Login | Create New User
IWETHEY Banner

Welcome to IWETHEY!

New Name and pointer unnecessary duplication
A function name and pointer are generally duplicated references to the same information. You essentially have 2 primary keys. Now maybe it is done for speed, but otherwise is a sloppy or compromized theoretical arrangment.

except that, in both cases, you seem to want the language to guess in the absence of information

There is no need for "guessing" if the duplication is removed.
________________
oop.ismad.com
New No, it isn't duplicated.
The function "pointer" is actually an object that contains a lot more information than a simple string can convey.
Regards,

-scott anderson

"Welcome to Rivendell, Mr. Anderson..."
New references versus the record itself
The function "pointer" is actually an object that contains a lot more information than a simple string can convey.

The string is like an ID that points to (references) a record, not the record itself. If it requires more, then make it an associative array, but I don't see a need for that so far either.

Someone below suggested that more is needed to implement closures. Personally I have not seen a slam-dunk justification for closures. They may simplify code a few percent at most. We had a huge debate here about this once and I see no need to repeat it again.
________________
oop.ismad.com
New ...and the duplication is necessary.
Once you realize that it's not just 2 copies, but n copies. In this way, you can have multiple bindings to the same object, to be used in different descriptive contexts (with its own semantics tht map to the appropriate problem domain). A local namespace can have a named reference to the object. A list can have an anonymous, but indexed, reference to the object. A hashmap/dictionary can possess a named reference which approaches worst-case O(n) lookup on the *name*, instead of on the value (the function pointer).

In other words, there's a reason we use variable names instead of register or memory addresses.
New You clearly do not know what a closure is
If you can figure out the following piece of code, then you'll understand how there can be many different copies of a function, all slightly distinct.
\nuse strict;\n\nnested_for(\n  sub {print "@_\\n";},\n  [1..2], ['a'..'c'], ['A'..'D']\n);\n\nsub nested_for {\n  ret_iter(@_)->();\n}\n\nsub ret_iter {\n  my $fn = shift;\n  my $range = shift;\n  my $sub = sub {$fn->($_, @_) for @$range};\n  return @_ ? ret_iter($sub, @_) : $sub;\n}\n

Cheers,
Ben
I have come to believe that idealism without discipline is a quick road to disaster, while discipline without idealism is pointless. -- Aaron Ward (my brother)
     Python and function pointers - (tablizer) - (16)
         No such thing as a fool-proof language. - (admin) - (2)
             I'll assume "fool" is not meant to label a specific person -NT - (tablizer) - (1)
                 Well, you know what they say about ASSuming... -NT - (Yendor)
         parse: 1 + 2 + "3" + 4 + 5 - (ChrisR)
         Gruh? - (FuManChu) - (8)
             Another language fight? - (tablizer) - (7)
                 What is there to fight about? - (FuManChu) - (6)
                     Explicit is definitely what Python is about - (admin)
                     Name and pointer unnecessary duplication - (tablizer) - (4)
                         No, it isn't duplicated. - (admin) - (1)
                             references versus the record itself - (tablizer)
                         ...and the duplication is necessary. - (FuManChu)
                         You clearly do not know what a closure is - (ben_tilly)
         Wrong forum. - (static)
         Please tell me the language(s) that do what you want - (ben_tilly)
         You want to use Rexx - (jake123)

I hope you don't mind if I don't read this. I don't know if it's going where I don't want it to be going, but if it is going there, I *don't* want to go there, so the best place for me to be is here, not there, and here is where I'm staying.
*puts on blinders*
*whistles very loudly*
*claws out own eyes*
64 ms