Index: wp-admin/includes/post.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-admin/includes/post.php	(revision 35119)
+++ wp-admin/includes/post.php	(revision )
@@ -618,7 +618,7 @@
 		$post->page_template = 'default';
 		$post->post_parent = 0;
 		$post->menu_order = 0;
-		$post = new WP_Post( $post );
+		$post = WP_Post::make_instance( $post );
 	}
 
 	/**
@@ -1844,4 +1844,4 @@
 	 */
 	wp_redirect( apply_filters( 'redirect_post_location', $location, $post_id ) );
 	exit;
-}
\ No newline at end of file
+}
Index: wp-includes/class-wp-post.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-includes/class-wp-post.php	(revision 35119)
+++ wp-includes/class-wp-post.php	(revision )
@@ -197,6 +197,41 @@
 	public $filter;
 
 	/**
+	 * Flag to disallow "new WP_Post()" to be called w/o deprecation warning.
+	 *
+	 * @var bool
+	 */
+	private static $_allow__construct = false;
+
+	/**
+	 * Retrieve virtual WP_Post instance.
+	 *
+	 * @static
+	 * @access public
+	 *
+	 * @param WP_Post|object|array $post Post value.
+	 * @return WP_Post|object Post object.
+	 */
+	public static function make_instance( $post ) {
+
+		if ( is_array( $post ) || 'stdClass' === get_class( $post ) ) {
+			self::$_allow__construct = true;
+			$post = new WP_Post( (object) $post );
+			self::$_allow__construct = false;
+		}
+
+		/**
+		 * Filter post object to be sanitized, virtualized and/or have properties annotated.
+		 *
+		 * @since 4.4.0
+		 *
+		 * @param WP_Post $post Post object to sanitize/virtualize/annotate/etc.
+		 */
+		return apply_filters( 'make_post_instance', $post );
+
+	}
+
+	/**
 	 * Retrieve WP_Post instance.
 	 *
 	 * @static
@@ -219,24 +254,46 @@
 		if ( ! $_post ) {
 			$_post = $wpdb->get_row( $wpdb->prepare( "SELECT * FROM $wpdb->posts WHERE ID = %d LIMIT 1", $post_id ) );
 
-			if ( ! $_post )
+			if ( ! $_post ) {
+
+				/**
+				 * Retrieve a virtual post instance based on its post_id
+				 *
+				 * @since 4.4.0
+				 *
+				 * @param int $post_id Virtual post object to retrieve
+				 */
+				$_post = apply_filters( 'get_virtual_post_instance', $post_id );
+
+				if ( ! $_post ) {
-				return false;
+					return false;
+				}
+			}
 
 			$_post = sanitize_post( $_post, 'raw' );
 			wp_cache_add( $_post->ID, $_post, 'posts' );
+
 		} elseif ( empty( $_post->filter ) ) {
+
 			$_post = sanitize_post( $_post, 'raw' );
+
 		}
 
-		return new WP_Post( $_post );
+		return self::make_instance( $_post );
+
 	}
 
 	/**
 	 * Constructor.
 	 *
-	 * @param WP_Post|object $post Post object.
+	 * @param WP_Post|object    $post       Post object.
 	 */
 	public function __construct( $post ) {
+
+		if ( ! self::$_allow__construct ) {
+			_deprecated_function( 'new ' . __CLASS__ . '()', '4.4', 'WP_Post::make_instance()' );
+		}
+
 		foreach ( get_object_vars( $post ) as $key => $value )
 			$this->$key = $value;
 	}
Index: wp-includes/post-functions.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-includes/post-functions.php	(revision 35119)
+++ wp-includes/post-functions.php	(revision )
@@ -433,9 +433,9 @@
 	} elseif ( is_object( $post ) ) {
 		if ( empty( $post->filter ) ) {
 			$_post = sanitize_post( $post, 'raw' );
-			$_post = new WP_Post( $_post );
+			$_post = WP_Post::make_instance( $_post );
 		} elseif ( 'raw' == $post->filter ) {
-			$_post = new WP_Post( $post );
+			$_post = WP_Post::make_instance( $post );
 		} else {
 			$_post = WP_Post::get_instance( $post->ID );
 		}
Index: wp-admin/includes/media.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-admin/includes/media.php	(revision 35119)
+++ wp-admin/includes/media.php	(revision )
@@ -1187,7 +1187,7 @@
 	if ( is_int($post) )
 		$post = get_post($post);
 	if ( is_array($post) )
-		$post = new WP_Post( (object) $post );
+		$post = WP_Post::make_instance( $post );
 
 	$image_url = wp_get_attachment_url($post->ID);
 
Index: wp-includes/class-wp-customize-setting.php
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
--- wp-includes/class-wp-customize-setting.php	(revision 35119)
+++ wp-includes/class-wp-customize-setting.php	(revision )
@@ -1348,7 +1348,7 @@
 
 		$item->ID = $this->post_id;
 		$item->db_id = $this->post_id;
-		$post = new WP_Post( (object) $item );
+		$post = WP_Post::make_instance( $item );
 
 		if ( empty( $post->post_author ) ) {
 			$post->post_author = get_current_user_id();
