test-console-output-regexp.html 567 B

123456789101112131415161718192021222324
  1. <!DOCTYPE HTML>
  2. <html dir="ltr" lang="en-US">
  3. <head>
  4. <meta charset="utf-8">
  5. <title>Test the web console output for RegExp</title>
  6. <!--
  7. - Any copyright is dedicated to the Public Domain.
  8. - http://creativecommons.org/publicdomain/zero/1.0/
  9. -->
  10. </head>
  11. <body>
  12. <p>hello world!</p>
  13. <script type="text/javascript">
  14. Object.defineProperty(RegExp.prototype, "flags", {
  15. get: function() { throw Error("flags called"); }
  16. })
  17. Object.defineProperty(RegExp.prototype, "source", {
  18. get: function() { throw Error("source called"); },
  19. })
  20. </script>
  21. </body>
  22. </html>