Index: src/wp-includes/link-template.php
===================================================================
--- src/wp-includes/link-template.php	(revision 34986)
+++ src/wp-includes/link-template.php	(working copy)
@@ -14,15 +14,17 @@
  *
  * @param int|WP_Post $id Optional. Post ID or post object. Default current post.
  */
-function the_permalink( $id = 0 ) {
+function the_permalink( $id = false ) {
 	/**
 	 * Filter the display of the permalink for the current post.
 	 *
 	 * @since 1.5.0
+	 * @since 4.4.0 $id param added
 	 *
 	 * @param string $permalink The permalink for the current post.
+	 * @param int|WP_Post $id   Optional. Post ID or post object. Default current post.
 	 */
-	echo esc_url( apply_filters( 'the_permalink', get_permalink( $id ) ) );
+	echo esc_url( apply_filters( 'the_permalink', get_permalink( $id ), $id ) );
 }
 
 /**
