Index: lib/AST/Expr.cpp
===================================================================
--- lib/AST/Expr.cpp	(revision 194056)
+++ lib/AST/Expr.cpp	(working copy)
@@ -3026,7 +3026,8 @@
 Expr::NullPointerConstantKind
 Expr::isNullPointerConstant(ASTContext &Ctx,
                             NullPointerConstantValueDependence NPC) const {
-  if (isValueDependent() && !Ctx.getLangOpts().CPlusPlus11) {
+  if (isValueDependent() &&
+      (!Ctx.getLangOpts().CPlusPlus11 || Ctx.getLangOpts().MicrosoftMode)) {
     switch (NPC) {
     case NPC_NeverValueDependent:
       llvm_unreachable("Unexpected value dependent expression!");
@@ -3108,8 +3109,13 @@
   if (Ctx.getLangOpts().CPlusPlus11) {
     // C++11 [conv.ptr]p1: A null pointer constant is an integer literal with
     // value zero or a prvalue of type std::nullptr_t.
+    // Microsoft mode permits C++98 rules reflecting MSVC behavior.
     const IntegerLiteral *Lit = dyn_cast<IntegerLiteral>(this);
-    return (Lit && !Lit->getValue()) ? NPCK_ZeroLiteral : NPCK_NotNull;
+    if (Lit && !Lit->getValue())
+      return NPCK_ZeroLiteral;
+    else if (!Ctx.getLangOpts().MicrosoftMode ||
+             !isCXX98IntegralConstantExpr(Ctx))
+      return NPCK_NotNull;
   } else {
     // If we have an integer constant expression, we need to *evaluate* it and
     // test for the value 0.
Index: test/SemaCXX/MicrosoftCompatibility.cpp
===================================================================
--- test/SemaCXX/MicrosoftCompatibility.cpp	(revision 194056)
+++ test/SemaCXX/MicrosoftCompatibility.cpp	(working copy)
@@ -178,3 +178,19 @@
     del((void*)a);  // expected-note {{in instantiation of function template specialization}}
   }
 }
+
+namespace IntToNullPtrConv {
+  struct Foo {
+    static const int ZERO = 0;
+    typedef void (Foo::*MemberFcnPtr)();
+  };
+
+  struct Bar {
+    const Foo::MemberFcnPtr pB;
+  };
+
+  Bar g_bar = { (Foo::MemberFcnPtr)Foo::ZERO };
+
+  template<int N> int *get_n() { return N; }   // expected-warning {{expression which evaluates to zero treated as a null pointer constant}}
+  int *g_nullptr = get_n<0>();  // expected-note {{in instantiation of function template specialization}}
+}
\ No newline at end of file
