Incomplete idea for @safe enhancement
Jacob Carlborg
doob at me.com
Thu Apr 25 21:22:14 UTC 2019
On 2019-04-25 14:42, RazvanN wrote:
> I would argue that this would be a good fit for a 3rd party tool that
> uses dmd as a library,
There you go [1]. This will infer all attributes for all functions that
are normally not inferred. It will only output attributes that are not
already declared. Here's the output of the "src/dmd/root/filename.d"
file in DMD:
src/dmd/root/filename.d:61:16: this: pure
src/dmd/root/filename.d:67:30: equals: @nogc
src/dmd/root/filename.d:73:28: equals: @nogc
src/dmd/root/filename.d:96:30: absolute: @nogc
src/dmd/root/filename.d:102:28: absolute: @nogc
src/dmd/root/filename.d:153:38: ext: @nogc
src/dmd/root/filename.d:195:31: ext: @nogc
src/dmd/root/filename.d:242:38: name: @nogc
src/dmd/root/filename.d:248:37: name: @nogc
src/dmd/root/filename.d:281:31: name: @nogc
src/dmd/root/filename.d:516:29: addExt: pure
src/dmd/root/filename.d:577:30: equalsExt: @nogc
src/dmd/root/filename.d:583:28: equalsExt: @nogc
src/dmd/root/filename.d:604:23: equalsExt: @nogc
src/dmd/root/filename.d:972:30: free: pure
src/dmd/root/filename.d:982:31: toChars: @nogc
src/dmd/root/filename.d:989:19: toString: @nogc
I'll try to make a new release tomorrow. There are a few additonal
things I would like to add before making a new release.
[1]
https://github.com/jacob-carlborg/dlp/commit/d41f717aeda7a2a0106d039bde954ab2610e1120
--
/Jacob Carlborg
More information about the Digitalmars-d
mailing list