On 11/01/2014 03:35 AM, David Schmitt wrote:
> On 2014-11-01 01:22, Henrik Lindberg wrote:
>
> The requirement to compare strings and numerals can also be
> implemented by converting the numeral to a string (using a canoical
> non-locale dependent format). This produces a much safer route, as
> creating a string has less degrees of freedom.
I believe this is the perl5 approach, which seems to be robust.
>>
>> * Add === operator to compare both type and value. This is a slippery
>> slope since we probably want Integer and Float to compare equal - say
>> 0.0 and 0. It adds yet another operator, and we have to decide what
>> case, selector and in should use since there is no way to specify if one
>> or the other should be used.
Oh hell no!
>>
>> # best effort, or fail
>> convert_to(Number, value)
It would require changes to the lexer but another syntactic option (not
that I'm advocating it) would be C style type coercion.

(String)$my_hungarian_integer

-Josh

--

-- 
You received this message because you are subscribed to the Google Groups 
"Puppet Developers" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to puppet-dev+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/puppet-dev/5455F711.80004%40cpan.org.
For more options, visit https://groups.google.com/d/optout.

Reply via email to