about summary refs log tree commit diff
diff options
context:
space:
mode:
authorGuillaume Gomez <guillaume1.gomez@gmail.com>2025-06-17 11:50:03 +0200
committerGuillaume Gomez <guillaume1.gomez@gmail.com>2025-06-17 11:50:03 +0200
commit2bbc974bede2f23953aa5fc81d6399811ab47400 (patch)
tree4404d35530e1453b1cf0df9ad059d5cd166f34b5
parent0cbc0764380630780a275c437260e4d4d5f28c92 (diff)
downloadrust-2bbc974bede2f23953aa5fc81d6399811ab47400.tar.gz
rust-2bbc974bede2f23953aa5fc81d6399811ab47400.zip
Lint about `console` calls in rustdoc JS
-rw-r--r--src/librustdoc/html/static/.eslintrc.js1
-rw-r--r--src/librustdoc/html/static/js/search.js1
2 files changed, 2 insertions, 0 deletions
diff --git a/src/librustdoc/html/static/.eslintrc.js b/src/librustdoc/html/static/.eslintrc.js
index fbb096fe9c7..303c5667140 100644
--- a/src/librustdoc/html/static/.eslintrc.js
+++ b/src/librustdoc/html/static/.eslintrc.js
@@ -91,5 +91,6 @@ module.exports = {
         "no-script-url": "error",
         "no-sequences": "error",
         "no-div-regex": "error",
+        "no-console": "error",
     }
 };
diff --git a/src/librustdoc/html/static/js/search.js b/src/librustdoc/html/static/js/search.js
index dce5fddb317..b611a3e501d 100644
--- a/src/librustdoc/html/static/js/search.js
+++ b/src/librustdoc/html/static/js/search.js
@@ -1133,6 +1133,7 @@ class RoaringBitmap {
         }
         for (let j = 0; j < size; ++j) {
             if (offsets && offsets[j] !== i) {
+                // eslint-disable-next-line no-console
                 console.log(this.containers);
                 throw new Error(`corrupt bitmap ${j}: ${i} / ${offsets[j]}`);
             }