STC: strictness of number and string type checking

2019-11-21 Thread Milles, Eric (TR Tech, Content & Ops)
I wanted to discuss the strictness of Groovy's static type checking before Groovy 3 is released and change becomes difficult. Recent changes have replaced some instances of type coercion with STC errors. It was suggested in one of the bug tickets to discuss before accepting the new strictness

Re: STC: strictness of number and string type checking

2019-11-21 Thread MG
Hi Eric, I  am using STC a lot i n my framework, and have run into problems with "too much strictness". My take would be: m1 : STC error - giving a floating point literal when an integer is expected could point towards an error, and there is no inconvenience in writing 1 instead of 1.0 . m2: