What kinds of commands can run with
exec? For example, executable files, builtin commands, shell script, compound commands (e.g. looping, conditional branching), pipeline, command list, commands grouped by parentheses or braces, ...?
Because the parent shell exits upon the command run with
exec finishes running, it is hard to tell if there is an error.