Skip to content

Instantly share code, notes, and snippets.

@ygit
Created May 11, 2019 20:33
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ygit/eebe1ac58988d21e569fcf6156701271 to your computer and use it in GitHub Desktop.
Save ygit/eebe1ac58988d21e569fcf6156701271 to your computer and use it in GitHub Desktop.
A xcrun bash script to demangle symbols
FILE=$1
ANOTHER_FILE=$2
exec 4> "$ANOTHER_FILE"
while read -ru 3 LINE; do
line="$LINE"
linearray=($line)
echo ${linearray[2]}
xcrun c++filt "${linearray[2]}" >&4
done 3< "$FILE"
# usage
#$ bash XcrunDemangleScript.sh mangledSymbolInput.txt output.txt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment