H1 2015 Priorities and Bare-Metal Programming

Steven Schveighoffer via Digitalmars-d digitalmars-d at puremagic.com
Tue Feb 3 05:37:45 PST 2015


On 2/2/15 5:34 PM, Jonathan M Davis via Digitalmars-d wrote:
> On Monday, February 02, 2015 13:01:28 Walter Bright via Digitalmars-d wrote:
>> On 2/2/2015 6:43 AM, Manu via Digitalmars-d wrote:
>>> I'm pretty sure the only controversy is that you want it to be a
>>> pragma, everyone else wants it to be an attribute.
>>
>> That's correct.
>>
>> My reasoning is simple - an attribute defines the semantics of the interface, a
>> pragma gives instructions to the compiler, and does not affect logical semantics.
>>
>> For example, attributes change the name mangling, because it affects the
>> semantic interface. A pragma would not.
>
> That makes sense, though the one issue that I see with making it a pragma is
> the fact that pragmas are supposed to be compiler-specific and not part of
> the language (at least as I understand it)

 From http://dlang.org/pragma.html#predefined-pragmas:

"All implementations must support these, even if by just ignoring them:"

I would believe that inline would definitely be one that could be 
ignored, seeing as the code generated whether inlining or not creates 
the same end result.

But you could put it under that list, and then most compilers will 
support it. Remember, all 3 major compilers here are based on the same 
front-end code.

-Steve



More information about the Digitalmars-d mailing list