MCPcopy Create free account
hub / github.com/CppCXY/EmmyLuaCodeStyle / InitRangeFormat

Function InitRangeFormat

CodeFormat/src/CodeFormat.cpp:256–270  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

254}
255
256bool InitRangeFormat(CommandLine &cmd, FormatContext &formatContext) {
257 InitFormat(cmd, formatContext);
258
259 if (cmd.HasOption("range-line")) {
260 formatContext.SetFormatRange(true, cmd.Get<std::string>("range-line"));
261 } else if (cmd.HasOption("range-offset")) {
262 formatContext.SetFormatRange(false, cmd.Get<std::string>("range-offset"));
263 }
264
265 if (cmd.HasOption("complete-output")) {
266 formatContext.EnableCompleteOutputRangeSupport();
267 }
268
269 return true;
270}

Callers 1

mainFunction · 0.85

Calls 4

InitFormatFunction · 0.85
HasOptionMethod · 0.80
SetFormatRangeMethod · 0.80

Tested by

no test coverage detected