示例
$ echo " char password[10][18]; struct NetworkVariable netVars[NUM_NETWORK_VARIABLES][2]" |sed -e 's/\[[^][]*\]//g'
结果
char password; struct NetworkVariable netVars
示例
$ echo " char password[10][18]; struct NetworkVariable netVars[NUM_NETWORK_VARIABLES][2]" |sed -e 's/\[[^][]*\]//g'
结果
char password; struct NetworkVariable netVars