This repository was archived by the owner on Dec 23, 2024. It is now read-only.
Commit c32e03f
[RFC FS-1001] String Interpolation (dotnet#8907)
* string interploation implementation
* string interploation tests
* escape {{ }}, test verbatim and triple quote, implement .NET specifiers
* fix tests
* string interpolation tests: internal representation corner cases
* string-interp tests should have --langversion:preview
* string interop tests: sprintf
* string interp tests: format specifier negative cases
* string interp tests: format specifier negative cases, .NET-style padding
* fix nested interp strings
* style cleanup
* lex: unify string interp stack and counter
* string-interp: add test cases
* fix mixed quote nested string interpolation
* string-interp: add test case for multiple interpolation points with different indentation
* lexfilter: push new CtxtParen at endPos for INTERP_STRING_PART and INTERP_STRING_BEGIN_PART
* lexfilter: do not check undentation limit for string interpolation tokens.
* FormattableString prototype
* add FormattableString support
* negative error checking
* remove diagnostics
* simpler FormattableString implementation
* fix test
* add testing for nested
* add IFormattable support
* tweak error message
* tests: StringInterpolation: fix case errors
* fix error message
* check number of values matches
* allow use of format strings with printf and friends
* update baselines
* fix baselines
* add Experimental attributes
* update string interp negative tests
* stringinterp test: add PrintFormat tests
* printf: fix empty interpolation string evaluates to null in printf env
* enable test corectly
* Revert "printf: fix empty interpolation string evaluates to null in printf env"
This reverts commit 7f39617.
* simplify codegen for interpolated strings
* fix build
* fix build
* Merge master to feature/string-interp (dotnet#9580)
* Update dependencies from https://github.com/dotnet/arcade build 20200626.2 (dotnet#9577)
Microsoft.DotNet.Arcade.Sdk
From Version 1.0.0-beta.20302.3 -> To Version 1.0.0-beta.20326.2
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
* Improve perf for String.filter up to 3x (dotnet#9509)
* Improve perf for String.filter 2-2.5x
* Cleanup: remove "foo" etc in tests
* Add tests for new execution path for LOH in String.filter
* Change test string
* String map performance improvement (dotnet#9470)
* Simplify and improve perf of String.length
* Improve performance of String.map
* Revert "Simplify and improve perf of String.length"
* Resolves dotnet#9470 (comment)
* Lingering space
* Change `String` to use `new` to clarify use of ctor
* Add some better tests for String.map, add side-effect test
* Add tests to ensure the mapping function is called a deterministically amount of times
* Fix typo
* Remove "foo" from String.map tests
* Perf: String.replicate from O(n) to O(log(n)), up to 12x speed improvement (dotnet#9512)
* Turn String.replicate from O(n) into O(log(n))
* Cleanup String.replicate tests by removing usages of "foo"
* String.replicate: add tests for missing cases, and for the new O(log(n)) cut-off points
* Improve String.replicate algorithm further
* Add tests for String.replicate covering all lines/branches of algo
* Fix accidental comment
Co-authored-by: dotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Abel Braaksma <abel.online@xs4all.nl>
* Re enable tests for operators: OperatorsModule1.fs and OperatorsModule2.fs (dotnet#9516) (dotnet#9589)
* Re-enabling tests from OperatorsModule1/2.fs (compile errors)
* Fix compile errors in OperatorsModule1/2.fs, fix tests. Note tanh test comment.
* Fix `tanh` test, ensure stable result on x86 vs x64 runtimes
* Stop using exception AssertionException, so that test window shows useful info
* Whitespace cleanup and redundant code removal
* Cleanup spelling etc
* Re-enabling int, int16, int32, int64, nativeint, incr, nullArg etc tests
* Special-case floating-point assertion messages for higher precision output
* Fix/update/add tests (some still failing)
* Separate Checked tests, add & fix others, differentiate framework/bitness for some tests
* Add branch for .NET Native (ignore cos test)
* Resorting to comparing floats with a delta using Assert.AreNearEqual
* Add some more tests
Co-authored-by: Abel Braaksma <abel.online@xs4all.nl>
* Moved fsharpqa/Libraries/Core/Unchecked test cases to NUnit (dotnet#9576) (dotnet#9599)
Co-authored-by: Thorsten Reichert <ThorstenReichert@users.noreply.github.com>
* Moved fsharpqa/Libraries/Core/Unchecked test cases to NUnit (dotnet#9576) (dotnet#9604)
Co-authored-by: Thorsten Reichert <ThorstenReichert@users.noreply.github.com>
* Merge master to feature/string-interp (dotnet#9615)
* Moved fsharpqa/Libraries/Core/Unchecked test cases to NUnit (dotnet#9576)
* Moved fsharpqa/Libraries/Core/Reflectiontest cases to NUnit (dotnet#9611)
* Migrated PreComputedTupleConstructor01.fs test case
* Migrated PreComputedTupleConstructor02.fs test case
* Migrated DU.fs and Record.fs test cases
* Allow notebook to discover location of shared framework (dotnet#9596)
Co-authored-by: Thorsten Reichert <ThorstenReichert@users.noreply.github.com>
Co-authored-by: Kevin Ransom (msft) <codecutter@hotmail.com>
Co-authored-by: Phillip Carter <pcarter@fastmail.com>
* Merge master to feature/string-interp (dotnet#9619)
* Moved fsharpqa/Libraries/Core/Unchecked test cases to NUnit (dotnet#9576)
* Moved fsharpqa/Libraries/Core/Reflectiontest cases to NUnit (dotnet#9611)
* Migrated PreComputedTupleConstructor01.fs test case
* Migrated PreComputedTupleConstructor02.fs test case
* Migrated DU.fs and Record.fs test cases
* Allow notebook to discover location of shared framework (dotnet#9596)
Co-authored-by: Thorsten Reichert <ThorstenReichert@users.noreply.github.com>
Co-authored-by: Kevin Ransom (msft) <codecutter@hotmail.com>
* Text tweeks
* don't auto-resolve types from System.Runtime.WindowsRuntime (dotnet#9644) (dotnet#9648)
Co-authored-by: Brett V. Forsgren <brettfo@microsoft.com>
* yeet (dotnet#9657) (dotnet#9661)
yeet
Co-authored-by: Phillip Carter <pcarter@fastmail.com>
* yeet (dotnet#9657) (dotnet#9670)
yeet
Co-authored-by: Phillip Carter <pcarter@fastmail.com>
* fix up tokenizer tests
* fix code review things
* fix code review things
* fix code review things
* fix code review things
* add various testing
* correct continuations for interpolated strings
* fix lexer continuations and colorization for multi-line interpolated strings
* revert xlf changes
* fix assert
* completion and brace matching (not all tests passing yet)
* Fix rebuild
* fix various niggles and get tests working
* fix printf when '%a' in final position
* fix test case
* interpolated string specifer highlighting
* fix triple quote interpolated string specifer highlighting
* fix triple quote interpolated string specifer highlighting
* fix build
* fix missing error message
* fix % specifiers for interpolated strings
* fix % specifiers for interpolated strings
* fix FCS tests
* minor nits from code review
* code review feedback and use struct tuples in more places
* revert struct tuples
* use struct tuples where possible, byrefs for index
* fix byref for index
* fix ksprintf block size
* make recent cache entry more explicit (cleanup)
* improve performance
* remove unused code
* Move existing Compiler.ComponentTests to a new Compiler.fs framework (dotnet#9839) (dotnet#9848)
* Move existing Compiler.ComponentTests to a new Compiler.fs framework; Add 'parse' function
* Changed some wording in error messages
Co-authored-by: Vlad Zarytovskii <vzaritovsky@hotmail.com>
* Move existing Compiler.ComponentTests to a new Compiler.fs framework (dotnet#9839)
* Move existing Compiler.ComponentTests to a new Compiler.fs framework; Add 'parse' function
* Changed some wording in error messages
* fix dotnet#9893
* fix unmantched right brace in interp string
Co-authored-by: Yatao Li <yatli@microsoft.com>
Co-authored-by: Kevin Ransom (msft) <codecutter@hotmail.com>
Co-authored-by: dotnet bot <dotnet-bot@dotnetfoundation.org>
Co-authored-by: dotnet-maestro[bot] <42748379+dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: dotnet-maestro[bot] <dotnet-maestro[bot]@users.noreply.github.com>
Co-authored-by: Abel Braaksma <abel.online@xs4all.nl>
Co-authored-by: Thorsten Reichert <ThorstenReichert@users.noreply.github.com>
Co-authored-by: Phillip Carter <pcarter@fastmail.com>
Co-authored-by: Brett V. Forsgren <brettfo@microsoft.com>
Co-authored-by: Vlad Zarytovskii <vzaritovsky@hotmail.com>1 parent 6eb435e commit c32e03f
File tree
54 files changed
+4631
-2106
lines changed- src/fsharp
- FSharp.Core
- fsi
- service
- tests
- FSharp.Compiler.UnitTests
- FSharp.Core.UnitTests
- FSharp.Test.Utilities
- fsharp
- Compiler/Language
- core
- printf-interpolated
- printf
- service
- data/CSharp_Analysis
- vsintegration
- src/FSharp.Editor
- AutomaticCompletion
- Completion
- tests/UnitTests
- LegacyLanguageService
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
54 files changed
+4631
-2106
lines changedLarge diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
| 12 | + | |
12 | 13 | | |
13 | 14 | | |
14 | 15 | | |
15 | | - | |
| 16 | + | |
16 | 17 | | |
17 | | - | |
| 18 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1166 | 1166 | | |
1167 | 1167 | | |
1168 | 1168 | | |
| 1169 | + | |
| 1170 | + | |
| 1171 | + | |
| 1172 | + | |
1169 | 1173 | | |
1170 | 1174 | | |
1171 | 1175 | | |
| |||
3588 | 3592 | | |
3589 | 3593 | | |
3590 | 3594 | | |
3591 | | - | |
3592 | | - | |
| 3595 | + | |
| 3596 | + | |
3593 | 3597 | | |
3594 | 3598 | | |
3595 | 3599 | | |
3596 | 3600 | | |
3597 | | - | |
| 3601 | + | |
3598 | 3602 | | |
3599 | 3603 | | |
3600 | 3604 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
702 | 702 | | |
703 | 703 | | |
704 | 704 | | |
705 | | - | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1490 | 1490 | | |
1491 | 1491 | | |
1492 | 1492 | | |
| 1493 | + | |
1493 | 1494 | | |
1494 | 1495 | | |
1495 | 1496 | | |
| |||
1509 | 1510 | | |
1510 | 1511 | | |
1511 | 1512 | | |
| 1513 | + | |
1512 | 1514 | | |
1513 | 1515 | | |
1514 | 1516 | | |
1515 | 1517 | | |
1516 | 1518 | | |
1517 | 1519 | | |
1518 | 1520 | | |
| 1521 | + | |
| 1522 | + | |
| 1523 | + | |
| 1524 | + | |
| 1525 | + | |
| 1526 | + | |
| 1527 | + | |
| 1528 | + | |
| 1529 | + | |
| 1530 | + | |
| 1531 | + | |
| 1532 | + | |
| 1533 | + | |
| 1534 | + | |
| 1535 | + | |
1519 | 1536 | | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
441 | 441 | | |
442 | 442 | | |
443 | 443 | | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
| 449 | + | |
| 450 | + | |
| 451 | + | |
| 452 | + | |
| 453 | + | |
| 454 | + | |
| 455 | + | |
444 | 456 | | |
445 | 457 | | |
446 | 458 | | |
| |||
0 commit comments