Skip to content

Commit 3d308fe

Browse files
committed
Remove the quad_precision_float feature gate
The f128 type has very little support in the compiler and the feature is basically unusable today. Supporting half-baked features in the compiler can be detrimental to the long-term development of the compiler, and hence this feature is being removed.
1 parent 719ffc2 commit 3d308fe

File tree

21 files changed

+4
-74
lines changed

21 files changed

+4
-74
lines changed

src/libcore/intrinsics.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,6 @@ pub trait TyVisitor {
9696

9797
fn visit_f32(&mut self) -> bool;
9898
fn visit_f64(&mut self) -> bool;
99-
fn visit_f128(&mut self) -> bool;
10099

101100
fn visit_char(&mut self) -> bool;
102101

src/libdebug/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@
2525
html_favicon_url = "http://www.rust-lang.org/favicon.ico",
2626
html_root_url = "http://doc.rust-lang.org/")]
2727
#![experimental]
28-
#![feature(managed_boxes, macro_rules, quad_precision_float)]
28+
#![feature(managed_boxes, macro_rules)]
2929
#![allow(experimental)]
3030

3131
pub mod fmt;

src/libdebug/reflect.rs

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -179,13 +179,6 @@ impl<V:TyVisitor + MovePtr> TyVisitor for MovePtrAdaptor<V> {
179179
true
180180
}
181181

182-
fn visit_f128(&mut self) -> bool {
183-
self.align_to::<f128>();
184-
if ! self.inner.visit_f128() { return false; }
185-
self.bump_past::<f128>();
186-
true
187-
}
188-
189182
fn visit_char(&mut self) -> bool {
190183
self.align_to::<char>();
191184
if ! self.inner.visit_char() { return false; }

src/libdebug/repr.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,6 @@ impl<'a> TyVisitor for ReprVisitor<'a> {
258258

259259
fn visit_f32(&mut self) -> bool { self.write::<f32>() }
260260
fn visit_f64(&mut self) -> bool { self.write::<f64>() }
261-
fn visit_f128(&mut self) -> bool { fail!("not implemented") }
262261

263262
fn visit_char(&mut self) -> bool {
264263
self.get::<char>(|this, &ch| {

src/libhexfloat/lib.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,6 @@ pub fn expand_syntax_ext(cx: &mut ExtCtxt, sp: Span, tts: &[ast::TokenTree])
112112
Some(Ident{ident, span}) => match token::get_ident(ident).get() {
113113
"f32" => Some(ast::TyF32),
114114
"f64" => Some(ast::TyF64),
115-
"f128" => Some(ast::TyF128),
116115
_ => {
117116
cx.span_err(span, "invalid floating point type in hexfloat!");
118117
None

src/librustc/front/feature_gate.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,7 @@ static KNOWN_FEATURES: &'static [(&'static str, Status)] = &[
6464
("overloaded_calls", Active),
6565
("unboxed_closure_sugar", Active),
6666

67-
("quad_precision_float", Active),
67+
("quad_precision_float", Removed),
6868

6969
// A temporary feature gate used to enable parser extensions needed
7070
// to bootstrap fix for #5723.
@@ -91,7 +91,6 @@ enum Status {
9191
/// A set of features to be used by later passes.
9292
pub struct Features {
9393
pub default_type_params: Cell<bool>,
94-
pub quad_precision_float: Cell<bool>,
9594
pub issue_5723_bootstrap: Cell<bool>,
9695
pub overloaded_calls: Cell<bool>,
9796
}
@@ -100,7 +99,6 @@ impl Features {
10099
pub fn new() -> Features {
101100
Features {
102101
default_type_params: Cell::new(false),
103-
quad_precision_float: Cell::new(false),
104102
issue_5723_bootstrap: Cell::new(false),
105103
overloaded_calls: Cell::new(false),
106104
}
@@ -425,7 +423,6 @@ pub fn check_crate(sess: &Session, krate: &ast::Crate) {
425423
sess.abort_if_errors();
426424

427425
sess.features.default_type_params.set(cx.has_feature("default_type_params"));
428-
sess.features.quad_precision_float.set(cx.has_feature("quad_precision_float"));
429426
sess.features.issue_5723_bootstrap.set(cx.has_feature("issue_5723_bootstrap"));
430427
sess.features.overloaded_calls.set(cx.has_feature("overloaded_calls"));
431428
}

src/librustc/metadata/tydecode.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,7 +330,6 @@ fn parse_ty(st: &mut PState, conv: conv_did) -> ty::t {
330330
'D' => return ty::mk_mach_int(ast::TyI64),
331331
'f' => return ty::mk_mach_float(ast::TyF32),
332332
'F' => return ty::mk_mach_float(ast::TyF64),
333-
'Q' => return ty::mk_mach_float(ast::TyF128),
334333
_ => fail!("parse_ty: bad numeric type")
335334
}
336335
}

src/librustc/metadata/tyencode.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,6 @@ fn enc_sty(w: &mut MemWriter, cx: &ctxt, st: &ty::sty) {
221221
match t {
222222
TyF32 => mywrite!(w, "Mf"),
223223
TyF64 => mywrite!(w, "MF"),
224-
TyF128 => mywrite!(w, "MQ")
225224
}
226225
}
227226
ty::ty_enum(def, ref substs) => {

src/librustc/middle/resolve.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -770,7 +770,6 @@ impl PrimitiveTypeTable {
770770
table.intern("char", TyChar);
771771
table.intern("f32", TyFloat(TyF32));
772772
table.intern("f64", TyFloat(TyF64));
773-
table.intern("f128", TyFloat(TyF128));
774773
table.intern("int", TyInt(TyI));
775774
table.intern("i8", TyInt(TyI8));
776775
table.intern("i16", TyInt(TyI16));

src/librustc/middle/trans/debuginfo.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1621,7 +1621,6 @@ fn basic_type_metadata(cx: &CrateContext, t: ty::t) -> DIType {
16211621
ty::ty_float(float_ty) => match float_ty {
16221622
ast::TyF32 => ("f32".to_string(), DW_ATE_float),
16231623
ast::TyF64 => ("f64".to_string(), DW_ATE_float),
1624-
ast::TyF128 => ("f128".to_string(), DW_ATE_float)
16251624
},
16261625
_ => cx.sess().bug("debuginfo::basic_type_metadata - t is invalid type")
16271626
};

0 commit comments

Comments
 (0)