-
Notifications
You must be signed in to change notification settings - Fork 1
Release 0.5.0 #5
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
Conversation
WalkthroughThis pull request introduces a new deterministic floating-point number type, Changes
|
WalkthroughThe changeset introduces a new object type called Changes
|
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.
Files selected (4)
- Runtime/GameLovers.DataExtensions.asmdef (1)
- Runtime/MathfloatP.cs (1)
- Runtime/floatP.cs (1)
- Tests/Editor/floatPTests.cs (1)
Files ignored due to filter (4)
- Runtime/MathfloatP.cs.meta
- Runtime/floatP.cs.meta
- Tests/Editor/floatPTests.cs.meta
- package.json
Files not summarized due to errors (2)
- Runtime/MathfloatP.cs (diff tokens exceeds limit)
- Runtime/floatP.cs (diff tokens exceeds limit)
Files skipped from review due to trivial changes (2)
- Runtime/MathfloatP.cs (diff too large)
- Runtime/floatP.cs (diff too large)
Review comments generated (3)
- Review: 1
- LGTM: 2
Tips
Chat with
CodeRabbit Bot (@coderabbitai
)
- Reply on review comments left by this bot to ask follow-up questions. A review comment is a comment on a diff or a file.
- Invite the bot into a review comment chain by tagging
@coderabbitai
in a reply.
Code suggestions
- The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
- You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.
Pausing incremental reviews
- Add
@coderabbitai: ignore
anywhere in the PR description to pause further reviews from the bot.
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.
Files ignored due to filter (1)
- package.json
Files selected for processing (7)
- Runtime/GameLovers.DataExtensions.asmdef (1 hunks)
- Runtime/MathfloatP.cs (1 hunks)
- Runtime/MathfloatP.cs.meta (1 hunks)
- Runtime/floatP.cs (1 hunks)
- Runtime/floatP.cs.meta (1 hunks)
- Tests/Editor/floatPTests.cs (1 hunks)
- Tests/Editor/floatPTests.cs.meta (1 hunks)
Files not summarized due to errors (1)
- Runtime/MathfloatP.cs (diff tokens exceeds limit)
Files skipped from review due to trivial changes (2)
- Runtime/MathfloatP.cs (diff too large)
- Runtime/floatP.cs (diff too large)
Review comments generated (5)
- Actionable : 5
- LGTM (Skipped): 3
- Noise Suppression (Skipped): 0
Tips
Chat with
CodeRabbit Bot (@coderabbitai
)
- Tag the bot with
@coderabbitai
in any review comment to ask it questions. The bot will not respond unless explicitly tagged. - A review comment is a comment on a diff or a file and not a comment on the PR itself.
- You can use the mouse to select multiple lines of code to provide exact context to the bot.
Code suggestions
- The bot may make code suggestions, but please review them carefully before committing since the line number ranges may be misaligned.
- You can edit the comment made by the bot and manually tweak the suggestion if it is slightly off.
Pausing incremental reviews
- Add
@coderabbitai: ignore
anywhere in the PR description to pause further reviews from the bot.
Assert.IsTrue(floatP.NaN != floatP.NaN); | ||
Assert.IsTrue(floatP.NaN.Equals(floatP.NaN)); | ||
Assert.IsTrue(floatP.Zero == -floatP.Zero); | ||
Assert.IsTrue(floatP.Zero.Equals(-floatP.Zero)); | ||
Assert.IsTrue(!(floatP.NaN > floatP.Zero)); | ||
Assert.IsTrue(!(floatP.NaN >= floatP.Zero)); | ||
Assert.IsTrue(!(floatP.NaN < floatP.Zero)); | ||
Assert.IsTrue(!(floatP.NaN <= floatP.Zero)); | ||
Assert.IsTrue(floatP.NaN.CompareTo(floatP.Zero) == -1); | ||
Assert.IsTrue(floatP.NaN.CompareTo(floatP.NegativeInfinity) == -1); | ||
Assert.IsTrue(!(-floatP.Zero < floatP.Zero)); | ||
} |
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.
The Equality
test checks the behavior of floatP.NaN
and floatP.Zero
in comparison operations. It would be beneficial to also test the behavior of other floatP
constants like floatP.PositiveInfinity
, floatP.NegativeInfinity
, floatP.One
, and floatP.MinusOne
in comparison operations.
+ Assert.IsTrue(floatP.PositiveInfinity > floatP.One);
+ Assert.IsTrue(floatP.NegativeInfinity < floatP.One);
+ Assert.IsTrue(floatP.One >= floatP.Zero);
+ Assert.IsTrue(floatP.MinusOne <= floatP.Zero);
Add new floatP object type to define a deterministic floating point
Summary by CodeRabbit
Release Notes:
floatP
to theGameLovers.DataExtensions
namespace.floatPTests
in theGameLoversEditor.DataExtensions.Tests
namespace, with three test methods (Representation()
,Equality()
, andAddition()
) to verify the behavior of thefloatP
object type.Summary by CodeRabbit
Release Notes
New Feature
floatP
, a deterministic floating-point number type, enhancing precision and predictability in mathematical operations.floatP
to support complex calculations.floatP
andfloat
types.Test
floatP
, ensuring its reliability and correctness in various scenarios.