| OLD | NEW |
| 1 // Copyright 2010 the V8 project authors. All rights reserved. | 1 // Copyright 2010 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 108 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 119 nan_symbol_(nan_symbol), | 119 nan_symbol_(nan_symbol), |
| 120 exponent_character_(exponent_character), | 120 exponent_character_(exponent_character), |
| 121 decimal_in_shortest_low_(decimal_in_shortest_low), | 121 decimal_in_shortest_low_(decimal_in_shortest_low), |
| 122 decimal_in_shortest_high_(decimal_in_shortest_high), | 122 decimal_in_shortest_high_(decimal_in_shortest_high), |
| 123 max_leading_padding_zeroes_in_precision_mode_( | 123 max_leading_padding_zeroes_in_precision_mode_( |
| 124 max_leading_padding_zeroes_in_precision_mode), | 124 max_leading_padding_zeroes_in_precision_mode), |
| 125 max_trailing_padding_zeroes_in_precision_mode_( | 125 max_trailing_padding_zeroes_in_precision_mode_( |
| 126 max_trailing_padding_zeroes_in_precision_mode) { | 126 max_trailing_padding_zeroes_in_precision_mode) { |
| 127 // When 'trailing zero after the point' is set, then 'trailing point' | 127 // When 'trailing zero after the point' is set, then 'trailing point' |
| 128 // must be set too. | 128 // must be set too. |
| 129 ASSERT(((flags & EMIT_TRAILING_DECIMAL_POINT) != 0) || | 129 DCHECK(((flags & EMIT_TRAILING_DECIMAL_POINT) != 0) || |
| 130 !((flags & EMIT_TRAILING_ZERO_AFTER_POINT) != 0)); | 130 !((flags & EMIT_TRAILING_ZERO_AFTER_POINT) != 0)); |
| 131 } | 131 } |
| 132 | 132 |
| 133 // Returns a converter following the EcmaScript specification. | 133 // Returns a converter following the EcmaScript specification. |
| 134 static const DoubleToStringConverter& EcmaScriptConverter(); | 134 static const DoubleToStringConverter& EcmaScriptConverter(); |
| 135 | 135 |
| 136 // Computes the shortest string of digits that correctly represent the input | 136 // Computes the shortest string of digits that correctly represent the input |
| 137 // number. Depending on decimal_in_shortest_low and decimal_in_shortest_high | 137 // number. Depending on decimal_in_shortest_low and decimal_in_shortest_high |
| 138 // (see constructor) it then either returns a decimal representation, or an | 138 // (see constructor) it then either returns a decimal representation, or an |
| 139 // exponential representation. | 139 // exponential representation. |
| (...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 368 | 368 |
| 369 private: | 369 private: |
| 370 DISALLOW_IMPLICIT_CONSTRUCTORS(StringToDoubleConverter); | 370 DISALLOW_IMPLICIT_CONSTRUCTORS(StringToDoubleConverter); |
| 371 }; | 371 }; |
| 372 | 372 |
| 373 } // namespace double_conversion | 373 } // namespace double_conversion |
| 374 | 374 |
| 375 } // namespace WTF | 375 } // namespace WTF |
| 376 | 376 |
| 377 #endif // DOUBLE_CONVERSION_DOUBLE_CONVERSION_H_ | 377 #endif // DOUBLE_CONVERSION_DOUBLE_CONVERSION_H_ |
| OLD | NEW |