Hi Joe! Do you have an ETA for getting F# 8 into LINQPad 8? It has some nifty new language features. Looks like it's supported by version 43.8.x of FSharp.Compiler.Service.
Accidental language switch.. I've gotten really used to using CTRL+- for navigate backwards, which is very effective when doing keyboard work. Press F12 to jump to definition, make a tweak, then CTRL+- to get back to your location. Except... when you accidentally hit CTRL+0 and change the language from C# Program to F# Program which immediately and destructively modifies your entire script.
There's now a guard in 8.1.2 to request confirmation before changing languages via a keyboard shortcut with scripts over 200 characters. https://www.linqpad.net/linqpad8.aspx#beta
Intellisense popup hangs on certain types. When you are rapidly typing lines of code back-to-back that require intellisense popups, I regularly get some type of weird 'hang' where the popup takes 1-2 seconds to popup and animates very slowly. A good example is the Stopwatch class - if the method name is 'above the fold' there is no issue, but if it requires scroll, it seems to be weirdly slow.
This should now be fixed in 8.1.2
Tuples. I use them a LOT for quick types, and they are very annoying in LINQPad. Anytime you are trying to write for example
>
var (r, c) = (0, 0);
var coord = (c:0, r:0);
This should also now be fixed - let me know how you get on with 8.1.2. Note that in the second case, the completion listing will still pop up, but it won't accept the completion on the : character unless the identifier can match to a parameter name in a method.
@pjsmith01 said:
Hi Joe! Do you have an ETA for getting F# 8 into LINQPad 8? It has some nifty new language features. Looks like it's supported by version 43.8.x of FSharp.Compiler.Service.
This is now available in 8.1.2. Let me know if you run into any problems.
Any chance the undo buffer could be extended? Perhaps infinite?
There are times where I have a script that I have and will build it out a lot, adding new things, deleting things, changing things around, etc. At some point, I then realize something I deleted or changed I want back to try elsewhere and try to undo back to it but often hitting the limit. Would also be helpful if undo states also included non-code changes as well (connection changes, package changes, etc.).
Side request: This might be mitigated if there was some form of version control for scripts/settings. Would be awesome if there was some git integration.
Not sure if this is a limitation of the Dump processing engine, a feature request, or a deficiency in named tuple handling. I initially thought the comment by @mellamokb covered this as well, but I see I was mistaken. Given the following code:
var reg = new Regex(@"(?<item>)\s\((?<errata>[^\)]+)\)", RegexOptions.Compiled);
var data = new List<string>()
{
"First (D A)",
"Second (B D)",
"Third (E C F)",
"Fourth (F A)",
"Fifth (D C B)",
};
var errataOrder = new Dictionary<string, int>()
{
{"D", 10},
{"A", 20},
{"B", 30},
{"E", 40},
{"F", 50},
{"C", 60},
};
data
.Select(d => reg.Match(d))
.Where(d => d.Success)
.Select(d => new
{
Item = d.Groups["item"].Value,
Errata = d.Groups["errata"].Value
.Split(' ')
.Select(v => (Element: v, Order: errataOrder[v]))
.OrderByDescending(v => v.Order)
})
.Dump();
the Intellisense for Errata appears as
However, the dumped output does not present the element names.
This happens because C# uses type erasure when compiling code with named tuple elements. The names that you assign to tuple elements exist only at compile-time.
You can work around this by using anonymous types instead:
data
.Select (d => reg.Match (d))
.Where (d => d.Success)
.Select (d => new
{
Item = d.Groups ["item"].Value,
Errata = d.Groups ["errata"].Value
.Split (' ')
.Select (v => new { Element = v, Order = errataOrder [v] })
.OrderByDescending (v => v.Order)
})
.Dump();
Comments
Hi Joe! Do you have an ETA for getting F# 8 into LINQPad 8? It has some nifty new language features. Looks like it's supported by version 43.8.x of FSharp.Compiler.Service.
There's now a guard in 8.1.2 to request confirmation before changing languages via a keyboard shortcut with scripts over 200 characters.
https://www.linqpad.net/linqpad8.aspx#beta
This should now be fixed in 8.1.2
>
This should also now be fixed - let me know how you get on with 8.1.2. Note that in the second case, the completion listing will still pop up, but it won't accept the completion on the
:
character unless the identifier can match to a parameter name in a method.This is now available in 8.1.2. Let me know if you run into any problems.
Any chance the undo buffer could be extended? Perhaps infinite?
There are times where I have a script that I have and will build it out a lot, adding new things, deleting things, changing things around, etc. At some point, I then realize something I deleted or changed I want back to try elsewhere and try to undo back to it but often hitting the limit. Would also be helpful if undo states also included non-code changes as well (connection changes, package changes, etc.).
Side request: This might be mitigated if there was some form of version control for scripts/settings. Would be awesome if there was some git integration.
Came across an issue with V8.1.3.
To reproduce run the following script
Then
The results tab should look exactly as they did after stage 2, but instead the results are scrolled so that the button is visible.
Works as expected in Linqpad 7.8.7 or in V8 if you skip step 2
Not sure if this is a limitation of the Dump processing engine, a feature request, or a deficiency in named tuple handling. I initially thought the comment by @mellamokb covered this as well, but I see I was mistaken. Given the following code:
the Intellisense for
Errata
appears asHowever, the dumped output does not present the element names.
This happens because C# uses type erasure when compiling code with named tuple elements. The names that you assign to tuple elements exist only at compile-time.
You can work around this by using anonymous types instead:
@JeffMercado - the buffer is now much larger.