Rename sym::nontrapping_fptoint.

This commit is contained in:
Nicholas Nethercote 2020-07-08 11:54:27 +10:00
parent 2002ebacfb
commit 026089bdb5
2 changed files with 10 additions and 6 deletions

View file

@ -658,7 +658,7 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
// `nontrapping-fptoint` target feature is activated. We'll use those if
// they are available.
if self.sess().target.target.arch == "wasm32"
&& self.sess().target_features.contains(&sym::nontrapping_fptoint)
&& self.sess().target_features.contains(&sym::nontrapping_dash_fptoint)
{
let src_ty = self.cx.val_ty(val);
let float_width = self.cx.float_width(src_ty);
@ -683,7 +683,7 @@ impl BuilderMethods<'a, 'tcx> for Builder<'a, 'll, 'tcx> {
// `nontrapping-fptoint` target feature is activated. We'll use those if
// they are available.
if self.sess().target.target.arch == "wasm32"
&& self.sess().target_features.contains(&sym::nontrapping_fptoint)
&& self.sess().target_features.contains(&sym::nontrapping_dash_fptoint)
{
let src_ty = self.cx.val_ty(val);
let float_width = self.cx.float_width(src_ty);

View file

@ -102,9 +102,13 @@ symbols! {
Union: "union",
}
// Symbols that can be referred to with rustc_span::sym::*. The symbol is
// the stringified identifier unless otherwise specified (e.g.
// `proc_dash_macro` represents "proc-macro").
// Pre-interned symbols that can be referred to with `rustc_span::sym::*`.
//
// The symbol is the stringified identifier unless otherwise specified, in
// which case the name should mention the non-identifier punctuation.
// E.g. `sym::proc_dash_macro` represents "proc-macro", and it shouldn't be
// called `sym::proc_macro` because then it's easy to mistakenly think it
// represents "proc_macro".
//
// As well as the symbols listed, there are symbols for the the strings
// "0", "1", ..., "9", which are accessible via `sym::integer`.
@ -567,7 +571,7 @@ symbols! {
non_exhaustive,
non_modrs_mods,
nontemporal_store,
nontrapping_fptoint: "nontrapping-fptoint",
nontrapping_dash_fptoint: "nontrapping-fptoint",
noreturn,
no_niche,
no_sanitize,