mirror of
https://github.com/notepad-plus-plus/notepad-plus-plus.git
synced 2025-08-26 12:18:31 +02:00
Release 5.5.3 (https://www.scintilla.org/scintilla553.zip) Released 19 October 2024. On Win32 change direction of horizontal mouse wheel and touchpad scrolling to match other applications. Bug #2449. Release 5.4.1 (https://www.scintilla.org/lexilla541.zip) Released 19 October 2024. Lexer added for Dart "dart". Pull request #265, Pull request #275. Lexer added for troff / nroff "troff". Pull request #264. Lexer added for Zig "zig". Pull request #267. C++: Fix crash for empty documentation comment keyword where '<' occurs at line end. F#: Include EOLs in the style range of SCE_FSHARP_COMMENTLINE. Stabilizes EOL detection when folding line comment groups. Issue #276. F#: Fix per-line folding in F# documents. Issue #277. HTML: Improve SGML/DTD lexing. Don't terminate SGML when > inside quoted string. Lex both [ and ] as SCE_H_SGML_DEFAULT. Nested sections handled instead of switching to SCE_H_SGML_ERROR. Issue #272. JavaScript: New SCE_HJ_TEMPLATELITERAL and SCE_HJA_TEMPLATELITERAL styles for template literals when lexer is hypertext, or xml. Issue #280. PHP: Fix failure to recognize PHP start "<?php' at end of document. Caused by not capping retrieval range at document end causing no text to be retrieved. Issue #269. Smalltalk: Fix scaled decimal numbers without decimal separator. Pull request #274. Fix #15228, fix #15368, fix #15650, close #15717
52 lines
2.0 KiB
Plaintext
52 lines
2.0 KiB
Plaintext
0 400 400 module FormatSpecifiersTest
|
|
1 400 400
|
|
0 400 400 let x = List.fold (*) 24.5 [ 1.; 2.; 3. ]
|
|
1 400 400
|
|
0 400 400 // expect "147.00"
|
|
0 400 400 printfn "Speed: %.2f m/s" x
|
|
0 400 400 printfn $"Speed: %.2f{x} m/s"
|
|
0 400 400 printfn $"Speed: {x:f2} m/s"
|
|
0 400 400 printfn $@"Speed: %.2f{x} m/s"
|
|
0 400 400 printfn @$"Speed: {x:f2} m/s"
|
|
1 400 400
|
|
0 400 400 // expect " 147%"
|
|
0 400 400 printfn """%% increase:% .0F%% over last year""" x
|
|
0 400 400 printfn $"""%% increase:% .0F{x}%% over last year"""
|
|
0 400 400 printfn $"""%% increase:{x / 100.,5:P0} over last year"""
|
|
0 400 400 printfn $@"""%% increase:% .0F{x}%% over last year"""
|
|
0 400 400 printfn @$"""%% increase:{x / 100.,5:P0} over last year"""
|
|
1 400 400
|
|
2 400 401 + // expect "1.5E+002"
|
|
0 401 400 | // NB: units should look like text even without a space
|
|
0 400 400 printfn @"Time: %-0.1Esecs" x
|
|
0 400 400 printfn $"Time: %-0.1E{x}secs"
|
|
0 400 400 printfn $"Time: {x:E1}secs"
|
|
0 400 400 printfn $@"Time: %-0.1E{x}secs"
|
|
0 400 400 printfn @$"Time: {x:E1}secs"
|
|
1 400 400
|
|
0 400 400 // expect "\" +147\""
|
|
0 400 400 printfn @"""Temp: %+12.3g K""" x
|
|
0 400 400 printfn $"""{'"'}Temp: %+12.3g{x} K{'"'}"""
|
|
0 400 400 printfn $"""{'"'}Temp: {'+',9}{x:g3} K{'"'}"""
|
|
0 400 400 printfn $@"""Temp: %+12.3g{x} K"""
|
|
0 400 400 printfn @$"""Temp: {'+',9}{x:g3} K"""
|
|
1 400 400
|
|
0 400 400 // Since F# 6.0
|
|
0 400 400 printfn @"%B" 0b1_000_000
|
|
0 400 400 printfn "%B" "\x40"B.[0]
|
|
0 400 400 printfn $"""%B{'\064'B}"""
|
|
0 400 400 printfn $@"""%B{0b1_000_000}"""
|
|
0 400 400 printfn @$"""%B{'\064'B}"""
|
|
1 400 400
|
|
0 400 400 // These don't work
|
|
0 400 400 printfn ``%.2f`` x
|
|
0 400 400 printfn $"%.2f" x
|
|
0 400 400 printfn $@"%.2f" x
|
|
0 400 400 printfn @$"%.2f" x
|
|
0 400 400 printfn $"%.2f {x}"
|
|
0 400 400 printfn $@"%.2f {x}"
|
|
0 400 400 printfn @$"%.2f {x}"
|
|
0 400 400 printfn $"""%.2f {x}"""
|
|
0 400 400 printfn $@"""%.2f {x}"""
|
|
0 400 400 printfn @$"""%.2f {x}"""
|
|
0 400 0 |