Closed jengelh closed 2 years ago
That's because ptr
is a cdecl keyword that's a shorthand for pointer
. Note that cdecl recognizes such words only when parsing English and not gibberish (which is why your explain
line works).
I could perhaps add code to check to see if a token is a cdecl keyword and include that in the error message. Cdecl already does that for C/C++ keywords, e.g.:
cdecl> declare switch as pointer to void
^
18: syntax error: "switch": name or operator expected ("switch" is a keyword)
but not currently for cdecl keywords.
As of 306ff626412a
, cdecl token checks are done.
The explain command's output is normally usable a command in its own right (and vice-versa), but this falls on its feet when the variable name is called ptr: