Opened 12 years ago
Last modified 11 years ago
#127 assigned defect
[Discuss] Handling of overloaded functions in command mode.
Reported by: | magne | Owned by: | Anya Helene Bagge |
---|---|---|---|
Priority: | high | Milestone: | m13.11 |
Component: | magnolia-eclipse | Version: | |
Keywords: | Cc: | ||
Blocked By: | Blocking: |
Description
How is it possible to access a specific instance of overloaded functions?
For instance, in sophus-src, Applications/ExperimentalTypes/several_libraries_boolean_integer32_floating64 has 4 overloaded versions of minus: unary and binary for Number and Float. Only the unary one for Number is accessible from the command line. Running "minus 3.4 4.3" gives an error message (wrong number of arguments). Running "minus 3.4" yield -3, i.e., the integer and not the float version.
Change History (2)
comment:1 by , 12 years ago
Status: | new → assigned |
---|---|
Summary: | Handling of overloaded functions in command mode. → [Discuss] Handling of overloaded functions in command mode. |
comment:2 by , 11 years ago
Priority: | low → high |
---|---|
Type: | enhancement → defect |
Note:
See TracTickets
for help on using tickets.
In the executable file the commands are now sorted, except that overloads of the same command appear in random order.
Two enhancements seem needed:
1) a consistent ordering of overloaded operations, e.g., first by command name, then by argument type
2) a technique for accessing a given instance of the overloaded operation. A solution is to give each operation a suffix, e.g., #n, which is optional to use.
Assume we have two overloads
in program xxx. Given the suggested rules, the following two calls are clear:
The first one is for Large, the second one is for Small.