为什么 mingw bin 目录中的 c++fit 无法返回预期结果? [英] why c++fit in mingw bin's dir can't return expected result?

查看:50
本文介绍了为什么 mingw bin 目录中的 c++fit 无法返回预期结果?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

为什么 mingw bin 目录中的 c++fit 不能返回正确的结果?

why c++fit in mingw bin's dir can't return right result?

C:\MinGW\bin>c++filt _Z5funcAv
_Z5funcAv

但是在 CentOS 系统中,c++filt 可以返回正确的结果.

but in CentOS system, the c++filt can return right result.

#c++filt _Z5funcAv
funcA()

如何理解?

推荐答案

刚遇到你的问题,因为我遇到了类似的问题 MinGW32.

Just came across your question, because I had a similar problem with MinGW32.

对我有用的是使用 -n 不要忽略前导下划线" 选项,所以我怀疑默认选项的设置有所不同:

What did work for me was using the -n "Do not ignore a leading underscore" option, so I suspect a difference in the default option's settings:

C:\MinGW\bin>c++filt -n _Z5funcAv
funcA()

C:\MinGW\bin>c++filt _Z5funcAv
_Z5funcAv

C:\MinGW\bin>c++filt __Z5funcAv
funcA()

C:\MinGW\bin>c++filt --version
GNU c++filt (GNU Binutils) 2.25.1
Copyright (C) 2014 Free Software Foundation, Inc.
This program is free software; you may redistribute it under the terms of
the GNU General Public License version 3 or (at your option) any later version.
This program has absolutely no warranty.

这篇关于为什么 mingw bin 目录中的 c++fit 无法返回预期结果?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆