diff --git a/misc/drupal.js b/misc/drupal.js
index 6fb336b56ec854eb2ece59af0b1e7fe3637cd0d3..927403ab1d11a9f1f2e09a7ebf433d2b0f95a660 100644
--- a/misc/drupal.js
+++ b/misc/drupal.js
@@ -21,8 +21,20 @@ if (isJsEnabled()) {
   document.documentElement.className = 'js';
 }
 
+/**
+ * The global Drupal variable.
+ */
 Drupal = { };
 
+/**
+ * Merge an object into the Drupal namespace.
+ *
+ * @param obj
+ *   The object that should be merged into the Drupal namespace. Arbitrary objects
+ *   containing functions, variables or other objects can be used. An example object
+ *   would be { settings: { tree: { '/js/menu/tree': { mid: 206 } } } }. This item
+ *   can now be accessed at Drupal.settings.tree['/js/menu/tree'].mid.
+ */
 Drupal.extend = function(obj) {
   for (var i in obj) {
     if (this[i]) {
@@ -32,7 +44,7 @@ Drupal.extend = function(obj) {
       this[i] = obj[i];
     }
   }
-}
+};
 
 /**
  * Make IE's XMLHTTP object accessible through XMLHttpRequest()