August 20, 2019 How to set a global var to a user defined section. | ||||
---|---|---|---|---|
| ||||
Hi: With gcc we can use _ attribute _((section("name")) var; how to same in dlang? |
August 20, 2019 Re: How to set a global var to a user defined section. | ||||
---|---|---|---|---|
| ||||
Posted in reply to lili | On Tuesday, 20 August 2019 at 17:33:17 UTC, lili wrote:
> Hi:
> With gcc we can use _ attribute _((section("name")) var; how to same in dlang?
As for C(++), not standardized in the language itself. With LDC:
import ldc.attributes : section;
@section("name")
__gshared int myGlobal;
|
Copyright © 1999-2021 by the D Language Foundation