Skip to content
This repository was archived by the owner on Oct 12, 2022. It is now read-only.

Commit d11d392

Browse files
authored
Merge pull request #3112 from pbackus/extern-safety
Add explicit @System attribute to extern functions merged-on-behalf-of: Nicholas Wilson <thewilsonator@users.noreply.github.com>
2 parents a65b7ec + 46f08a6 commit d11d392

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

src/core/internal/parseoptions.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import core.internal.traits : externDFunc;
1818

1919

2020
@nogc nothrow:
21-
extern extern(C) string[] rt_args();
21+
extern extern(C) string[] rt_args() @system;
2222

2323
extern extern(C) __gshared bool rt_envvars_enabled;
2424
extern extern(C) __gshared bool rt_cmdline_enabled;

src/rt/config.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ import core.stdc.ctype : toupper;
6161
import core.stdc.stdlib : getenv;
6262
import core.stdc.string : strlen;
6363

64-
extern extern(C) string[] rt_args() @nogc nothrow;
64+
extern extern(C) string[] rt_args() @nogc nothrow @system;
6565

6666
alias rt_configCallBack = string delegate(string) @nogc nothrow;
6767

test/exceptions/src/rt_trap_exceptions.d

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Code adapted from
22
// http://arsdnet.net/this-week-in-d/2016-aug-07.html
33
extern extern(C) __gshared bool rt_trapExceptions;
4-
extern extern(C) int _d_run_main(int, char**, void*);
4+
extern extern(C) int _d_run_main(int, char**, void*) @system;
55

66
extern(C) int main(int argc, char** argv) {
77
rt_trapExceptions = false;

0 commit comments

Comments
 (0)