Skip to content

Replace STCxxx with STC enum#7629

Merged
dlang-bot merged 2 commits intodlang:masterfrom
wilzbach:STC
Jan 8, 2018
Merged

Replace STCxxx with STC enum#7629
dlang-bot merged 2 commits intodlang:masterfrom
wilzbach:STC

Conversation

@wilzbach
Copy link
Contributor

@wilzbach wilzbach commented Jan 8, 2018

The second commit was done automatically:

replacements=(
"STCautoref autoref"
"STCinference inference"
"STCinit init"
"STCscopeinferred scopeinferred"
"STCundefined undefined_"
"STCstatic static_"
"STCextern extern_"
"STCconst const_"
"STCfinal final_"
"STCabstract abstract_"
"STCparameter parameter"
"STCfield field"
"STCoverride override_"
"STCauto auto_"
"STCsynchronized synchronized_"
"STCdeprecated deprecated_"
"STCin in_"
"STCout out_"
"STClazy lazy_"
"STCforeach foreach_"
"STCvariadic variadic"
"STCctorinit ctorinit"
"STCtemplateparameter templateparameter"
"STCscope scope_"
"STCimmutable immutable_"
"STCref ref_"
"STCmanifest manifest"
"STCnodtor nodtor"
"STCnothrow nothrow_"
"STCpure pure_"
"STCtls tls"
"STCalias alias_"
"STCshared shared_"
"STCgshared gshared"
"STCwild wild"
"STCproperty property"
"STCsafe safe"
"STCtrusted trusted"
"STCsystem system"
"STCctfe ctfe"
"STCdisable disable"
"STCresult result"
"STCnodefaultctor nodefaultctor"
"STCtemp temp"
"STCrvalue rvalue"
"STCnogc nogc"
"STCvolatile volatile_"
"STCreturn return_"
"STCexptemp exptemp"
"STCmaybescope maybescope"
"STCfuture future"
"STClocal local"
"STC_TYPECTOR TYPECTOR"
"STC_FUNCATTR FUNCATTR"
)
for r in "${replacements[@]}" ; do
    w=($r)
    sed "s/${w[0]}/STC.${w[1]}/g" -i **/*.d
done

@wilzbach wilzbach requested a review from WalterBright as a code owner January 8, 2018 03:44
@dlang-bot
Copy link
Contributor

Thanks for your pull request, @wilzbach!

Bugzilla references

Your PR doesn't reference any Bugzilla issue.

If your PR contains non-trivial changes, please reference a Bugzilla issue or create a manual changelog.

@wilzbach wilzbach added the Review:WIP Work In Progress - not ready for review or pulling label Jan 8, 2018
@wilzbach wilzbach force-pushed the STC branch 2 times, most recently from 9b86a89 to c001545 Compare January 8, 2018 03:57
@wilzbach
Copy link
Contributor Author

wilzbach commented Jan 8, 2018

Recent precedents: #7319 or #7328

@wilzbach wilzbach removed the Review:WIP Work In Progress - not ready for review or pulling label Jan 8, 2018
@WalterBright
Copy link
Member

"The build failed on Semaphore" I clicked on "Details" and could not find any information on what failed.

@wilzbach
Copy link
Contributor Author

wilzbach commented Jan 8, 2018

"The build failed on Semaphore" I clicked on "Details" and could not find any information on what failed.

  • I don't exactly know what failed, either but it seems to work know
  • I agree that their UI isn't the best. You can expand the individual build run to see the build run:

image

As mentioned in #7617, this is just an experiment motivated by (1) Travis increasing failures and (2) the fact that SemaphoreCI runs the entire test-suite 2x (with a host compiler and self-bootstrapped) and Phobos in 8 minutes (Travis takes about 25 mins).


TYPECTOR = (STC.const_ | STC.immutable_ | STC.shared_ | STC.wild),
FUNCATTR = (STC.ref_ | STC.nothrow_ | STC.nogc | STC.pure_ | STC.property | STC.safe | STC.trusted | STC.system),
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FWIW I'm still not a huge friend of this code duplication in ast*

```
replacements=(
"STCautoref autoref"
"STCinference inference"
"STCinit init"
"STCscopeinferred scopeinferred"
"STCundefined undefined_"
"STCstatic static_"
"STCextern extern_"
"STCconst const_"
"STCfinal final_"
"STCabstract abstract_"
"STCparameter parameter"
"STCfield field"
"STCoverride override_"
"STCauto auto_"
"STCsynchronized synchronized_"
"STCdeprecated deprecated_"
"STCin in_"
"STCout out_"
"STClazy lazy_"
"STCforeach foreach_"
"STCvariadic variadic"
"STCctorinit ctorinit"
"STCtemplateparameter templateparameter"
"STCscope scope_"
"STCimmutable immutable_"
"STCref ref_"
"STCmanifest manifest"
"STCnodtor nodtor"
"STCnothrow nothrow_"
"STCpure pure_"
"STCtls tls"
"STCalias alias_"
"STCshared shared_"
"STCgshared gshared"
"STCwild wild"
"STCproperty property"
"STCsafe safe"
"STCtrusted trusted"
"STCsystem system"
"STCctfe ctfe"
"STCdisable disable"
"STCresult result"
"STCnodefaultctor nodefaultctor"
"STCtemp temp"
"STCrvalue rvalue"
"STCnogc nogc"
"STCvolatile volatile_"
"STCreturn return_"
"STCexptemp exptemp"
"STCmaybescope maybescope"
"STCfuture future"
"STClocal local"
"STC_TYPECTOR TYPECTOR"
"STC_FUNCATTR FUNCATTR"
)
for r in "${replacements[@]}" ; do
    w=($r)
    sed "s/${w[0]}/STC.${w[1]}/g" -i **/*.d
done
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants