[ 
http://dev.sourcefabric.org/browse/LS-595?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=19057#action_19057
 ] 

David Baelde commented on LS-595:
---------------------------------

Nice catch, this is a bug, or at least a very bad design of list.nth(): it 
raises Failure "nth" when the index is too large.

> Add exceptions to the language
> ------------------------------
>
>                 Key: LS-595
>                 URL: http://dev.sourcefabric.org/browse/LS-595
>             Project: Liquidsoap
>          Issue Type: New Feature
>            Reporter: Samuel Mimram
>
> Some of the generic functions operating on lists are restricted to lists of 
> strings. For instance:
> _[_] : (string,[(string*string)])->string
> list.assoc : (string,[(string*string)])->string
> list.hd : ([string])->string
> etc.
> For the two first, this might just be that association lists should be 
> generalized to be able to contain any elements indexed by strings. But 
> list.hd is clearly a bug.
> Notice that this is not the case for all functions operating on lists for 
> instance:
> list.length : (['a])->int
> list.tl : (['a])->['a]

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://dev.sourcefabric.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Get your Android app more play: Bring it to the BlackBerry PlayBook 
in minutes. BlackBerry App World™ now supports Android™ Apps 
for the BlackBerry® PlayBook™. Discover just how easy and simple 
it is! http://p.sf.net/sfu/android-dev2dev
_______________________________________________
Savonet-devl mailing list
Savonet-devl@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/savonet-devl

Répondre à