Skip to content

Commit

Permalink
Implement JSON[ @@toStringTag ] (#1224)
Browse files Browse the repository at this point in the history
  • Loading branch information
Razican committed May 22, 2021
1 parent 5d4497b commit a8e434c
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
1 change: 0 additions & 1 deletion boa/src/builtins/json/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,6 @@ impl BuiltIn for Json {
let _timer = BoaProfiler::global().start_event(Self::NAME, "init");

let to_string_tag = WellKnownSymbols::to_string_tag();

let attribute = Attribute::READONLY | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE;

let json_object = ObjectInitializer::new(context)
Expand Down
7 changes: 0 additions & 7 deletions boa/src/builtins/math/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,6 @@ impl BuiltIn for Math {

let _timer = BoaProfiler::global().start_event(Self::NAME, "init");

let to_string_tag = context.well_known_symbols().to_string_tag_symbol();

let attribute = Attribute::READONLY | Attribute::NON_ENUMERABLE | Attribute::PERMANENT;
let string_tag = WellKnownSymbols::to_string_tag();
let object = ObjectInitializer::new(context)
Expand All @@ -48,11 +46,6 @@ impl BuiltIn for Math {
.property("SQRT1_2", 0.5_f64.sqrt(), attribute)
.property("SQRT2", f64::consts::SQRT_2, attribute)
.property("PI", f64::consts::PI, attribute)
.property(
to_string_tag,
"Math",
Attribute::READONLY | Attribute::NON_ENUMERABLE | Attribute::CONFIGURABLE,
)
.function(Self::abs, "abs", 1)
.function(Self::acos, "acos", 1)
.function(Self::acosh, "acosh", 1)
Expand Down

0 comments on commit a8e434c

Please sign in to comment.