linksplatform / linksplatform/Converters
Think of a mechanism for different resolution of conversion conflicts
Nobody has claimed this yet.
- Dominant language
- C#
- Stars
- 0
- Forks
- 1
- PR merge metrics
- No merged PRs in 30d
Description
Based on:
https://github.com/linksplatform/Converters/blob/8c5940357b2ef68292422b169da6fec5f69f3201/To.cs#L12-L18
If a source type value is greater than the target type's `MaxValue` it is called a conversion conflict.
The current way to resolve it is to use target type's `MaxValue` as _the closest matching value_.
There different ways to resolve the same conflict:
* Throw an exception.
* Reset value to default.
* `System.Convert` logic.
* Use of explicit `IConvertible` interface implementations, for example [Int64.IConvertible.ToInt32](https://docs.microsoft.com/en-us/dotnet/api/system.int64.system-iconvertible-toint32?view=netframework-4.8)
* Other user-defined behavior.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with To.cs lines 12-18 and trace how values above the target type's MaxValue are currently handled. Compare the listed resolution strategies, including System.Convert and explicit IConvertible implementations, and determine the API and behavior needed for user-defined choices. Done means the project has an agreed mechanism for selecting and testing conflict resolution behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- csharp
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100