Commit graph

5 commits

Author SHA1 Message Date
Cyrus Najmabadi ceeeb9cd11 Always preserve new lines for array and object literals and additional constructs like blocks. 2015-03-26 13:46:35 -07:00
Cyrus Najmabadi c371f1e521 Make the preservation of formatting an optional experimental compiler flag. 2015-03-08 19:06:55 -07:00
Cyrus Najmabadi 2a990a8685 Preserve newlines for conditional expressions 2015-03-07 13:50:26 -08:00
Cyrus Najmabadi a82289c8b4 Emit comments in a lot more places. 2015-01-22 15:58:00 -08:00
Sheetal Nandi e79bec5cbf TypeGuards narrow types in if statement works per spec:
The type of a variable or parameter is narrowed in the following situations:
•	In the true branch statement of an ‘if’ statement, the type of a variable or parameter is narrowed by any type guard in the ‘if’ condition when true, provided the if statement contains no assignments to the variable or parameter.
•	In the false branch statement of an ‘if’ statement, the type of a variable or parameter is narrowed by any type guard in the ‘if’ condition when false, provided the if statement contains no assignments to the variable or parameter.
2014-11-06 13:04:08 -08:00