I want to be in
ifThe conditional statement determines whether the suffix of the current file is equal to a suffix, but
%:t:e=="cpp"It seems that it is not the correct grammar. What is the correct grammar?
You need to use expand
if expand('<afile>:t:e') == "cpp"