Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Anchorsupdate#588

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
danmoseley merged 14 commits intodotnet:feature/regexsrmfromveanes:anchorsupdate
Feb 5, 2021
Merged

Conversation

veanes
Copy link

First major integration of SRM into .NET Regex.
Includes support for anchors and initial unit tests.

@dnfadmin
Copy link

dnfadmin commentedJan 25, 2021
edited
Loading

CLA assistant check
All CLA requirements met.

@veanes
Copy link
Author

As agreed, I added a public RegexOtions.DFA enum that triggers SRM from within the regex Run method.

@veanes
Copy link
Author

Did a major rewrite of the core SRM matcher engine, now with full anchor support.
The code became much simpler and straightforward with a different (new) mechanism
for handling of anchors. Still some unit tests fail and some bugs are to be fixed.

@@ -1,7 +1,7 @@
using System;
using System.Diagnostics;

namespaceMicrosoft.SRM
namespaceSystem.Text.RegularExpressions.SRM
{
[Serializable]
internal struct RegexOptions
Copy link
Member

Choose a reason for hiding this comment

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

Now that you're merging the code, seems the SRM versions of IgnoreCase, etc can be replaced by simply using the existing enum? And maybe retaining some of your helper methods here but no more need for any "mapping" from one to the other.

Copy link
Author

Choose a reason for hiding this comment

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

Right, removed SRM.RegexOptions.

InitializeReferences();
}

/// <summary>
/// This method is here for perf reasons: if InitializeSRM is NOT called in the
/// Init method, we don't load SRM.Regex when instantiating a regex that does not use the DFA option
Copy link
Member

Choose a reason for hiding this comment

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

Now it's all in the same assembly, does no-inlining matter? The type will be loaded anyway, and Jitting will only happen if it ends up needing the code.

Copy link
Author

Choose a reason for hiding this comment

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

Removed the comment and the complier method attribute. Added another note there as a reminder that in fact RightToLeft can be supported now -- fairly easily I think.

Copy link
Member

@danmoseleydanmoseley left a comment

Choose a reason for hiding this comment

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

I didn't review the SRM parts, but looks good to me

@veanes
Copy link
Author

This is great! Thanks!

@veanes
Copy link
Author

I fixed the merge conflict in the project files.

@danmoseley
Copy link
Member

@veanes thanks, as you saw I did a big merge to bring everything up to date. That probably introduced the file header check as well.

@danmoseleydanmoseley merged commit9ac521b intodotnet:feature/regexsrmFeb 5, 2021
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@danmoseleydanmoseleydanmoseley approved these changes

@stephentoubstephentoubAwaiting requested review from stephentoubstephentoub is a code owner

Assignees
No one assigned
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@veanes@dnfadmin@danmoseley

[8]ページ先頭

©2009-2025 Movatter.jp