Last Comment Bug 772691 - ban xml in function defaults
: ban xml in function defaults
Status: RESOLVED FIXED
:
Product: Core
Classification: Components
Component: JavaScript Engine (show other bugs)
: unspecified
: All All
: -- normal (vote)
: mozilla16
Assigned To: :Benjamin Peterson
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2012-07-10 16:41 PDT by :Benjamin Peterson
Modified: 2012-07-11 09:31 PDT (History)
2 users (show)
ryanvm: in‑testsuite+
See Also:
Crash Signature:
(edit)
QA Whiteboard:
Iteration: ---
Points: ---
Has Regression Range: ---
Has STR: ---


Attachments
ban XML in defaults (5.40 KB, patch)
2012-07-10 17:15 PDT, :Benjamin Peterson
n.nethercote: review+
Details | Diff | Splinter Review

Description :Benjamin Peterson 2012-07-10 16:41:53 PDT
Even after bug 769072, you can put XML in function defaults like:
function f(a=<x/>) { "use strict"; }

This is because XML doesn't report strict errors. Let's just completely ban XML in defaults.
Comment 1 :Benjamin Peterson 2012-07-10 17:15:33 PDT
Created attachment 640865 [details] [diff] [review]
ban XML in defaults

Not exactly straight forward, but I think we're escaping E4X with only a few scratches.
Comment 2 Nicholas Nethercote [:njn] 2012-07-10 17:37:43 PDT
Comment on attachment 640865 [details] [diff] [review]
ban XML in defaults

Review of attachment 640865 [details] [diff] [review]:
-----------------------------------------------------------------

The best thing about this patch is that it will be removed in the not-too-distant future, when e4x is removed :)
Comment 3 Ryan VanderMeulen [:RyanVM] 2012-07-10 18:42:57 PDT
https://hg.mozilla.org/integration/mozilla-inbound/rev/ee74ca523ff2
Comment 4 Ed Morley [:emorley] 2012-07-11 09:31:49 PDT
https://hg.mozilla.org/mozilla-central/rev/ee74ca523ff2

Note You need to log in before you can comment on or make changes to this bug.