-
-
Notifications
You must be signed in to change notification settings - Fork 45
Dev #1780
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
Dev #1780
Conversation
… substraction with numbers that do not fit into a 32 bit integer. See #1764
…ues to overflow into an Int64 value. The Usual constructor for type Int64 now returns a Int32 when the value lies between Int32.MinValue and Int32.MaxValue
…r returns an Int32 value when possible and to handle additions on Enums correctly. Restored the constructor for USUAL(INT64) to its original state.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR merges changes from the dev branch to main, introducing support for global usings in XSharp projects and fixing arithmetic overflow issues in the runtime.
Key Changes:
- Adds a new Global Usings property page for managing implicit namespace imports
- Fixes integer overflow handling by returning Int64 for Int32 arithmetic operations
- Changes WinBool internal storage from BYTE to INT for better compatibility
- Removes legacy Microsoft .xaml configuration files that are no longer needed
Reviewed changes
Copilot reviewed 76 out of 80 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
src/VisualStudio/XSharpCodeModelXs/Settings/Strings.prg |
Adds string constants for new Global Usings property page |
src/VisualStudio/ProjectPackage/XSharpShellEvents.cs |
Adds event handler to restore TargetFrameworks on project close |
src/VisualStudio/ProjectPackage/Nodes/XSharpSdkProjectNode.cs |
Adds BuildProject.Save() calls after property modifications |
src/VisualStudio/ProjectPackage/Nodes/XSharpProjectNode.cs |
Registers new Global Usings property page and removes trailing whitespace |
src/VisualStudio/AppDesigner/XSharp.AppDesigner2022.pkgdef |
Registers COM components for property pages |
src/VisualStudio/AppDesigner/PropertyPages/XGlobalUsingsPropertyPage*.cs |
Implements new Global Usings property page UI and logic |
src/Runtime/XSharp.RT/Types/WinBool.prg |
Changes internal storage from BYTE to INT |
src/Runtime/XSharp.RT/Types/Usual.prg |
Adds overflow detection for Int32 addition/subtraction |
src/Runtime/MacroCompiler/Compiler/MacroCodeblock.cs |
Converts Int64 results back to Int32 when in range |
src/Runtime/MacroCompiler/Binder/Operator.Binary.cs |
Updates operator resolution for Int32*Int32 to return Int64 |
src/Compiler/src/Compiler/XSharpBuildTask/XSharp.props |
Adds implicit global using declarations |
src/Compiler/src/Compiler/XSharpBuildTask/XSharp.GenerateGlobalUsings.targets |
New MSBuild target for generating global usings |
src/Compiler/src/Compiler/XSharpBuildTask/Utilities.cs |
Refactors boolean conversion utilities into Extensions class |
src/CompilerTests/Applications/C950/Prg/C950.prg |
Test case for integer multiplication overflow fix |
| Microsoft .xaml files | Removes numerous legacy Microsoft configuration files |
Files not reviewed (2)
- src/VisualStudio/AppDesigner/PropertyPages/XGeneralPropertyPagePanel.Designer.cs: Language not supported
- src/VisualStudio/AppDesigner/PropertyPages/XGlobalUsingsPropertyPagePanel.Designer.cs: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Merge changes from dev to main