You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
casting something into a list returns unexpected behaviours:
list("few words");
returns an empty list instead of a list containing the string "few words" or the list of characters that compose it.
Even stranger is:
list([1::2]);
this expression returns [2], which to me is the least obvious result, it could be either [1,2] or [1::2] but a list containing only 2 makes no sense from the user's point of view (though I understand it's the pair's value).
What is even stranger is that:
list(pair(1::2));
returns [1::2], why do we have to explicitly cast the pair into a pair while it's declared with a literal ?
Describe the bug
casting something into a list returns unexpected behaviours:
returns an empty list instead of a list containing the string "few words" or the list of characters that compose it.
Even stranger is:
this expression returns
[2], which to me is the least obvious result, it could be either[1,2]or[1::2]but a list containing only 2 makes no sense from the user's point of view (though I understand it's the pair's value).What is even stranger is that:
returns
[1::2], why do we have to explicitly cast the pair into a pair while it's declared with a literal ?