D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 11728 - compile error in std.bigint and -profile
Summary: compile error in std.bigint and -profile
Status: RESOLVED WORKSFORME
Alias: None
Product: D
Classification: Unclassified
Component: phobos (show other issues)
Version: D2
Hardware: All All
: P2 normal
Assignee: No Owner
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-12 03:43 UTC by Musashi Tamura
Modified: 2020-03-21 03:56 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description Musashi Tamura 2013-12-12 03:43:33 UTC
// aaa.d
import std.bigint;
void main() {
    BigInt a = "0";
}

> dmd -profile aaa
Error: 'std.internal.math.biguintcore.BigUint.__invariant' is not nothrow

This error is new in v2.064. (does not occur in v2.063)

Issue 10295 seems similar, but occurs in v2.063.
Comment 1 Musashi Tamura 2013-12-12 03:47:46 UTC
Issue 10295 occurs in v2.063 and v2.064.
Comment 2 yebblies 2013-12-12 06:52:53 UTC
Same sort of thing as issue 11375 - the nothrow inference/checking in FuncDeclaration::semantic is a mess.  The general problem is the compiler checks/infers nothrowness, then adds more stuff to the function body.  The error occurs because later the compiler uses blockExit(tf->isnothrow) to decide if the profiling exit code needs to be wrapped in a try-finally or not.
Comment 3 basile-z 2017-11-15 19:08:35 UTC
fixed at some point.