Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Code changes to keep NET 8 analyzers happy #1685

Merged
merged 1 commit into from
Nov 18, 2023

Conversation

lahma
Copy link
Collaborator

@lahma lahma commented Nov 18, 2023

No description provided.

@lahma lahma merged commit 6653ec8 into sebastienros:main Nov 18, 2023
3 checks passed
@lahma lahma deleted the net8-analyzers branch November 18, 2023 16:08
@@ -605,7 +605,7 @@ public JsValue Escape(JsValue thisObject, JsValue[] arguments)
for (var k = 0; k < strLen; k++)
{
var c = uriString[k];
if (WhiteList.IndexOf(c) != -1)
if (AllowList.Contains(c))
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This list can be ordered, so we should be able to use a binary search instead of Contains.

We also need to use SearchValues in some places, probably mostly in Esprima. But that means a net8.0 target.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants