Skip to content
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

Add Futures::Type Custom #1915

Merged
merged 1 commit into from Feb 21, 2024

Conversation

eltoder
Copy link
Contributor

@eltoder eltoder commented Feb 21, 2024

This allows passing custom future dates. Closes #1855

@coveralls
Copy link

coveralls commented Feb 21, 2024

Coverage Status

coverage: 72.477%. remained the same
when pulling 1917baf on eltoder:feature/custom-future-type
into 72012a7 on lballabio:master.

default:
QL_FAIL("unknown futures type (" << Integer(type) << ')');
QL_FAIL("unknown futures type (" << type << ')');
Copy link
Owner

Choose a reason for hiding this comment

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

Without the cast to Integer, this is going to trigger the QL_FAIL in operator<< — in this case the message will be the same, but in others the message there will override the original one.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Removed QL_FAIL from operator<<, so now it is safe to use.

@lballabio lballabio added this to the Release 1.34 milestone Feb 21, 2024
This allows passing custom future dates. Closes lballabio#1855
@lballabio lballabio merged commit 012754d into lballabio:master Feb 21, 2024
48 checks passed
@eltoder eltoder deleted the feature/custom-future-type branch February 21, 2024 19:28
ninetiger pushed a commit to ninetiger/QLNet that referenced this pull request Apr 15, 2024
This is trnasfered from the C++ code: lballabio/QuantLib#1915
This allows passing custom future dates. Closes #1855: lballabio/QuantLib#1855
amaggiulli pushed a commit to amaggiulli/QLNet that referenced this pull request Apr 16, 2024
* Added Futures Type - Custom;

This is trnasfered from the C++ code: lballabio/QuantLib#1915
This allows passing custom future dates. Closes #1855: lballabio/QuantLib#1855

* Update the default case message only

---------

Co-authored-by: Xiao Gong <xiao.gong@nzfunds.co.nz>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Customize future dates in FutureRateHelpers
3 participants