Feature #138
Improve automatic param conversion of funcitons
| Status: | New | Start: | 10/24/2009 | |
| Priority: | Normal | Due date: | ||
| Assigned to: | % Done: | 0% |
||
| Category: | C++-API | |||
| Target version: | 0.10 | |||
Description
I think how function params are treated needs a bit of tidying:
- Optional params should use
boost::optional, otherwise they are required - The number of params passed to a function must be at least as many as the required params
- This would mean that
(value x, optional< value > y, value z)would be invalid. If this is too hard to do, then just make the last param be optional too. - But you can pass more than the number of formal params, even if we can't access them (without using a
call_context)- this is just how JS works
- This would mean that
- An (explicit or implicit)
undefinedshould not be accepted for anything but avaluetyped param (See#127)
Related issues
| related to Bug #137 | encodings.convertFromString (and ToString) need better errors | Closed | 10/24/2009 | ||
| related to Bug #127 | automatic function params accepting numbers as objects (assert issues) | Closed | 10/06/2009 | ||
| related to Feature #12 | Evaluate conversion API | Assigned | 03/29/2009 |
History
Updated by Ash Berlin 226 days ago
I just got bit by the 3rd point above - expecting an object and it happily accept undefined confusing the crap out of me.