Open wmjordan opened 2 months ago
Beta 9978 allows us to define our own set of regular expressions to highlight our documents.
Here's an example of extra highlight of a markdown file.
Beta 9988 adds syntax highlight support for parameters in C# primary constructors.
Discovered a small issue with Super Quick Info.
When a type implements a static method with generic type parameters, hovering over the implementation does not list the corresponding Interface and Interface's static abstract member being implemented:
interface ISomething<This, TNum> where This : ISomething<This, TNum> where TNum : unmanaged, INumber<TNum> {
static abstract This CreateFromOtherNumber<TNumOther>(TNumOther a, TNumOther b) where TNumOther : unmanaged, INumber<TNumOther>;
}
struct Something : ISomething<Something, int> {
// Hovering over CreateFromOtherNumber member does NOT show that it is an implementation of ISomething<This, TNum>.CreateFromOtherNumber
public static Something CreateFromOtherNumber<TNumOther>(TNumOther a, TNumOther b) where TNumOther : unmanaged, INumber<TNumOther> => default;
}
@fitdev
Your snippet has syntax error. Generic type named TNum
is undefined.
It is not possible to display implementation when the parameter is wrong.
Sorry that was a typo, it should have been TNumOther
there. Then it works. And the issue remains.
Sorry that was a typo, it should have been
TNumOther
there. Then it works. And the issue remains.
The code was still wrong. You should see the following error if you are running the most recent preview version of VS:
CS0425: The constraints for type parameter 'TNumOther' of method 'Something.CreateFromOtherNumber
(TNumOther, TNumOther)' must match the constraints for type parameter 'TNumOther' of interface method 'ISomething<Something, int>.CreateFromOtherNumber (TNumOther, TNumOther)'. Consider using an explicit interface implementation instead.
I have corrected the code above, I replaced TNum
with TNumOther
in 2 places:
interface ISomething<This, TNum> where This : ISomething<This, TNum> where TNum : unmanaged, INumber<TNum> {
static abstract This CreateFromOtherNumber<TNumOther>(TNumOther a, TNumOther b) where TNumOther : unmanaged, INumber<TNumOther>;
}
struct Something : ISomething<Something, int> {
// Hovering over CreateFromOtherNumber member does NOT show that it is an implementation of ISomething<This, TNum>.CreateFromOtherNumber
public static Something CreateFromOtherNumber<TNumOther>(TNumOther a, TNumOther b) where TNumOther : unmanaged, INumber<TNumOther> => default;
}
@fitdev Please download and test the new beta.
@fitdev Please download and test the new beta.
File not found new version Codist 10003 @wmjordan
@tranbinhnghia Weird! The download was just updated. Please try again.
@tranbinhnghia Weird! The download was just updated. Please try again.
Thank you, I have downloaded the file.
Thank you for a quick fix! Works great!
@fitdev Please help test it. I don't know whether this fix can break somewhere else (but limited to implementation Quick Info only).
There is a new beta version which supports highlighting the output window pane.
To make it work, please see the Wiki page.
Please help test it.
The missing interface member implementation mention in the Super Quick Info now displays correctly. Thank you for the fix!
I will let you know if I encounter any issues.
Just wondering... Now that VS has released CodeLens API - any plans to use it in Codist?
@fitdev The VisualStudio.Extensibility thing has been out for quite some years, but not yet officially released.
Once it is used, the support to previous VS version (2017 and 2019) will be probably broken. Since I still have VS 2017 installed on my computer and I have not yet find a must-have usage of the new API, I will keep an eye on it, but stick to the old one unless there is enough motivation for me to move to the new onw.
This is a very early stage of the new version of Codist 8.
Download
Codist 10052
Codist 10033 Codist 10003 Codist 9988 Codist 9978 Codist 9961
What's New
<code>
and<hr>
in C# XML Doc (#326)