diff --git a/src/qdoc/cppcodemarker.cpp b/src/qdoc/cppcodemarker.cpp
index 1667f485b070703b290320d786cc19e5ee329c47..5e8c3a37bf799d9c9fe5638ec732707fe7bf87a9 100644
--- a/src/qdoc/cppcodemarker.cpp
+++ b/src/qdoc/cppcodemarker.cpp
@@ -841,6 +841,13 @@ QList<Section> CppCodeMarker::sections(const Aggregate *inner,
                         }
                     }
                     break;
+                case Node::SharedComment:
+                    {
+                        SharedCommentNode *scn = static_cast<SharedCommentNode *>(*n);
+                        if (!scn->doc().isEmpty())
+                            insert(functions, scn, style, status);
+                    }
+                    break;
                 default:
                     break;
                 }