现象:Qt无法调试Qvector-LMLPHP

解决:

打开文件 $(VSDIR)\Common7\Packages\Debugger\autoexp.dat (VSDIR是本机Visual Studio的安装目录)
把定义QVector和QMap显示内容的语句改成以下语句

;------------------------------------------------------------------------------
; QVector, QStack
;------------------------------------------------------------------------------
QVector<*>|*::QVector<*>|QStack<*>|*::QStack<*>{
    preview
    (
        #if ($c.d->size <= 10) (
            #(
                "[", $c.d->size, "](",
                #array
                (
                    expr: (($T1*)((char*)($c.d)+ $c.d->offset))[$i],
                    size: $c.d->size
                ), ")"
            )
        ) #else (
            #(
                "[", $c.d->size, "](",
                #array
                (
                    expr: (($T1*)((char*)($c.d)+ $c.d->offset))[$i],
                    size: $c.d->size
                ), ", ...)"
            )
        )
    )
    children
    (
        #array
        (
            expr: (($T1*)((char*)($c.d)+ $c.d->offset))[$i],
            size: $c.d->size
        )
    )
} ;------------------------------------------------------------------------------
; QMap
;------------------------------------------------------------------------------
QMapNode<*,*>{
    preview
    (
        #(
            "(",
            $e.key,
            "; ",
            $e.value,
            ")"
        )
    )     children
    (
        #(
            key: $e.key,
            value: $e.value
        )
    )
}
QMap<*>{
    children
    (
        #(
            raw data: [$c,!],
       #tree
  (
head: &($e.d->header),
size: $e.d->size,
left: left,
right: right,
) : ((QMapNode<$T1>*)&$e)         )
    )     preview
    (
        #(
            "[",
            $e.d->size,
            "](",
  #tree
  (
head: &($e.d->header),
size: $e.d->size,
left: left,
right: right,
) : ((QMapNode<$T1>*)&$e),
            ")"
        )
    )
}
05-11 17:45