Skip to content
Snippets Groups Projects
Commit ed77dcb9 authored by Jonathan Wakely's avatar Jonathan Wakely
Browse files

libstdc++: Check static assertions earlier in chrono::duration

This ensures that we fail a static assertion before giving any other
errors. Instantiating chrono::duration<int, chrono::seconds> will now
print this before the other errors caused by it:

error: static assertion failed: period must be a specialization of ratio

libstdc++-v3/ChangeLog:

	* include/bits/chrono.h (duration): Check preconditions on
	template arguments before using them.
parent 94f7baf2
No related branches found
No related tags found
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment