Since version 24, Emacs supports a generic mode called prog-mode. Like
all other modes it has its own mode-hook, prog-mode-hook. For Emacs
users it is common to provide all your generic programming-mode related
customizations in this mode-hook.
cmake-mode is definitely a programming-mode and should support calling
this hook. There are two ways to make that happen:
* Make your major-mode a derived-mode from prog-mode.
* Manually calling the hook upon mode-activation.
Implementing a derived mode may be the most proper thing to do, but that
may require quite a few structural changes. For now just call the hook
explicitly if it exists. This should cover much of what users need.
The Makefile is a configure-time concept, and the LocalGenerator
is a generate time concept. The LocalGenerator should not be available
from the Makefile.
820986ed cmLocalGenerator: Constify GetIncludeDirectories method.
b3e2e332 QtAutogen: Get the global generator from the Makefile.
61c0113c cmLocalUnixMakefileGenerator3: Remove unused method.
080489b8 cmMakefile: Use member directly instead of through method.
8bfaadfa cmMakefile: Move IsRoot API from cmLocalGenerator.
217c243d cmake: Update the current snapshot when Resetting.
eb05dcd6 cmLocalGenerator: Add IssueMessage method.
cfae7fa4 cmMakefile: Use cmOutputConverter instead of cmLocalGenerator.
ccf7760f cmOutputConverter: Constify API.
782657db cmListFileArgument: Remove FilePath member.
a863c59f cmMakefile: Use GetExecutionFileStack method.
076760a6 cmMakefile: Add filename context to ExpandArguments.
569f4785 cmFunctionCommand: Store the FilePath when creating the prototype.
f971ab04 cmMacroCommand: Store the FilePath when creating the prototype.
The fix in commit v3.2.3~3^2 (Fix assertion failure on unmatched foreach
in function, 2015-05-18) broke handling of unmatched non-loop blocks
because it assumed all function blockers removed during error unwinding
were for loops, essentially switching the set of mishandled cases.
The purpose of the loop block push/pop operations is to define a scope
matching the lifetime of the loop function blockers. Since our function
blockers already have the proper lifetime, simply move the push/pop
operations to their constructor/destructor.
Extend the RunCMake.Syntax test with a case covering this.
The cmListFileArgument currently stores a FilePath for use in this
method. The filename is the same as the CMAKE_CURRENT_LIST_FILE,
except if executing a macro or function defined in another file.
Set the context filename when expanding the arguments of macros and
functions using the filename recorded when defining the prototype.