Index: wp-includes/widgets/class-wp-widget-recent-posts.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-includes/widgets/class-wp-widget-recent-posts.php	(revision 006ae74d4cc6126d31079b6749fb167091dcbce4)
+++ wp-includes/widgets/class-wp-widget-recent-posts.php	(revision )
@@ -39,58 +39,14 @@
 	 * @param array $instance Settings for the current Recent Posts widget instance.
 	 */
 	public function widget( $args, $instance ) {
-		if ( ! isset( $args['widget_id'] ) ) {
-			$args['widget_id'] = $this->id;
-		}
 
-		$title = ( ! empty( $instance['title'] ) ) ? $instance['title'] : __( 'Recent Posts' );
+		$widget_template = 'widget-templates/recent-posts.php';
 
-		/** This filter is documented in wp-includes/widgets/class-wp-widget-pages.php */
-		$title = apply_filters( 'widget_title', $title, $instance, $this->id_base );
-
-		$number = ( ! empty( $instance['number'] ) ) ? absint( $instance['number'] ) : 5;
-		if ( ! $number )
-			$number = 5;
-		$show_date = isset( $instance['show_date'] ) ? $instance['show_date'] : false;
-
-		/**
-		 * Filter the arguments for the Recent Posts widget.
-		 *
-		 * @since 3.4.0
-		 *
-		 * @see WP_Query::get_posts()
-		 *
-		 * @param array $args An array of arguments used to retrieve the recent posts.
-		 */
-		$r = new WP_Query( apply_filters( 'widget_posts_args', array(
-			'posts_per_page'      => $number,
-			'no_found_rows'       => true,
-			'post_status'         => 'publish',
-			'ignore_sticky_posts' => true
-		) ) );
-
-		if ($r->have_posts()) :
-		?>
-		<?php echo $args['before_widget']; ?>
-		<?php if ( $title ) {
-			echo $args['before_title'] . $title . $args['after_title'];
-		} ?>
-		<ul>
-		<?php while ( $r->have_posts() ) : $r->the_post(); ?>
-			<li>
-				<a href="<?php the_permalink(); ?>"><?php get_the_title() ? the_title() : the_ID(); ?></a>
-			<?php if ( $show_date ) : ?>
-				<span class="post-date"><?php echo get_the_date(); ?></span>
-			<?php endif; ?>
-			</li>
-		<?php endwhile; ?>
-		</ul>
-		<?php echo $args['after_widget']; ?>
-		<?php
-		// Reset the global $the_post as this query will have stomped on it
-		wp_reset_postdata();
-
-		endif;
+		if ( $template = locate_template( $widget_template ) ) {
+			include $template;
+		} else {
+			include ABSPATH . WPINC . '/' . $widget_template;
+		}
 	}
 
 	/**
Index: wp-includes/widget-templates/recent-posts.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-includes/widget-templates/recent-posts.php	(revision )
+++ wp-includes/widget-templates/recent-posts.php	(revision )
@@ -0,0 +1,54 @@
+<?php
+
+if ( ! isset( $args['widget_id'] ) ) {
+	$args['widget_id'] = $this->id;
+}
+
+$title = ( ! empty( $instance['title'] ) ) ? $instance['title'] : __( 'Recent Posts' );
+
+/** This filter is documented in wp-includes/widgets/class-wp-widget-pages.php */
+$title = apply_filters( 'widget_title', $title, $instance, $this->id_base );
+
+$number = ( ! empty( $instance['number'] ) ) ? absint( $instance['number'] ) : 5;
+if ( ! $number )
+	$number = 5;
+$show_date = isset( $instance['show_date'] ) ? $instance['show_date'] : false;
+
+/**
+ * Filter the arguments for the Recent Posts widget.
+ *
+ * @since 3.4.0
+ *
+ * @see WP_Query::get_posts()
+ *
+ * @param array $args An array of arguments used to retrieve the recent posts.
+ */
+$r = new WP_Query( apply_filters( 'widget_posts_args', array(
+	'posts_per_page'      => $number,
+	'no_found_rows'       => true,
+	'post_status'         => 'publish',
+	'ignore_sticky_posts' => true
+) ) );
+
+if ($r->have_posts()) :
+	?>
+	<?php echo $args['before_widget']; ?>
+	<?php if ( $title ) {
+	echo $args['before_title'] . $title . $args['after_title'];
+} ?>
+	<ul>
+		<?php while ( $r->have_posts() ) : $r->the_post(); ?>
+			<li>
+				<a href="<?php the_permalink(); ?>"><?php get_the_title() ? the_title() : the_ID(); ?></a>
+				<?php if ( $show_date ) : ?>
+					<span class="post-date"><?php echo get_the_date(); ?></span>
+				<?php endif; ?>
+			</li>
+		<?php endwhile; ?>
+	</ul>
+	<?php echo $args['after_widget']; ?>
+	<?php
+	// Reset the global $the_post as this query will have stomped on it
+	wp_reset_postdata();
+
+endif;
\ No newline at end of file
