-
Notifications
You must be signed in to change notification settings - Fork 11
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
Additional filtering of namespaces #305
Merged
Merged
Commits on May 1, 2024
-
The most significant changes involve the addition of a foreach loop i…
…n the `CsOnlinerSourceBuilder` and `CsPlainSourceBuilder` classes, which iterates over the `UsingDirectives` of the `fileSyntax` object and adds each `UsingDirective` to the source code with the appropriate namespace. Additionally, the `class_extended_by_known_type.g.cs` and `file_with_usings.g.cs` files have been updated to include more `using` directives, importing namespaces related to `Simatic.Ax.Stateframework`, `Simatic.Ax.StatePattern`, and various `FileWithUsings` namespaces. 1. The `CsOnlinerSourceBuilder` and `CsPlainSourceBuilder` classes have been updated to include a foreach loop that iterates over the `UsingDirectives` of the `fileSyntax` object. This loop adds each `UsingDirective` to the source code with the appropriate namespace. The `CsOnlinerSourceBuilder` adds the namespace as is, while the `CsPlainSourceBuilder` prepends "Pocos." to the namespace. 2. The `class_extended_by_known_type.g.cs` and `file_with_usings.g.cs` files have been updated to include additional `using` directives. These directives import namespaces related to the `Simatic.Ax.Stateframework`, `Simatic.Ax.StatePattern`, and various `FileWithUsings` namespaces. 3. The `class_extended_by_known_type.g.cs` and `file_with_usings.g.cs` files have also been updated to include additional `using` directives under the `Pocos` namespace. These directives import the same namespaces as above, but under the `Pocos` namespace.
Configuration menu - View commit details
-
Copy full SHA for 3527285 - Browse repository at this point
Copy the full SHA 3527285View commit details -
The most significant changes involve the modification of several meth…
…ods to change the parameter type from `ISyntaxToken` to `PragmaSyntax`. This includes the `AddToDictionaryIfLocalizedString`, `IsPragmaToken`, and `IsStringToken` methods. Additionally, the `IterateSyntaxTreeForPragmas` method has been uncommented and modified, and the `IterateSyntaxTreeForStringLiterals` method has been commented out. The `IsStringToken` method now checks for different `SyntaxKind` types. 1. The `IterateSyntaxTreeForStringLiterals` method has been commented out, disabling its execution. 2. The `IterateSyntaxTreeForPragmas` method has been uncommented and modified. The `token` variable now refers to `pragmaSyntax` and the `IsAttributeNamePragmaToken` method checks the `PragmaContent` of the `token`. 3. The `AddToDictionaryIfLocalizedString` method's parameter type has been changed from `ISyntaxToken` to `PragmaSyntax`. The `TryToGetLocalizedStrings` method now checks the `PragmaContent` of the `token`. 4. The `pos` variable in the `AddToDictionaryIfLocalizedString` method now gets its value from `token.SourceText.GetLineSpan(token.Span).StartLinePosition`. 5. The `IsPragmaToken` and `IsStringToken` methods' parameter type has been changed from `ISyntaxToken` to `PragmaSyntax`. The check for `SyntaxKind.PragmaToken` in `IsPragmaToken` has been commented out. 6. The `IsStringToken` method now checks if the `SyntaxKind` of the `token` is `TypedStringDToken`, `TypedStringSToken`, `UntypedStringDToken`, or `UntypedStringSToken`.
Configuration menu - View commit details
-
Copy full SHA for 820e517 - Browse repository at this point
Copy the full SHA 820e517View commit details -
The most significant changes involve updates to the `CsOnlinerSourceB…
…uilder` and `CsPlainSourceBuilder` classes, which now filter `UsingDirectives` based on the presence of the namespace's fully qualified name in the semantic tree of the compilation. This is achieved through a LINQ query. Changes: 1. The `CsOnlinerSourceBuilder` and `CsPlainSourceBuilder` classes have been updated to filter `UsingDirectives` based on whether the fully qualified name of the namespace is present in the semantic tree of the compilation. This is done using a LINQ query that checks if the `FullyQualifiedName` of each namespace in the semantic tree is contained in the `QualifiedIdentifierList` of the `UsingDirectives`.
Configuration menu - View commit details
-
Copy full SHA for bea2722 - Browse repository at this point
Copy the full SHA bea2722View commit details -
Configuration menu - View commit details
-
Copy full SHA for 521db19 - Browse repository at this point
Copy the full SHA 521db19View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1b5743b - Browse repository at this point
Copy the full SHA 1b5743bView commit details
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.