Index: wp-includes/link-template.php
--- wp-includes/link-template.php
+++ wp-includes/link-template.php
@@ -11,9 +11,12 @@
  *
  * @since 1.2.0
  * @uses apply_filters() Calls 'the_permalink' filter on the permalink string.
+ *
+ * @param int $id Optional. Post ID.
+ * @param bool $leavename Optional, defaults to false. Whether to keep post name or page name.
  */
-function the_permalink() {
-	echo esc_url( apply_filters( 'the_permalink', get_permalink() ) );
+function the_permalink( $id = 0, $leavename = false ) {
+	echo esc_url( apply_filters( 'the_permalink', get_permalink( $id, $leavename ) ) );
 }
