@@ -35,23 +35,23 @@ class COFFMasmParser : public MCAsmParserExtension {
3535 getParser ().addDirectiveHandler (Directive, Handler);
3636 }
3737
38- bool ParseSectionSwitch (StringRef SectionName, unsigned Characteristics);
38+ bool parseSectionSwitch (StringRef SectionName, unsigned Characteristics);
3939
40- bool ParseSectionSwitch (StringRef SectionName, unsigned Characteristics,
40+ bool parseSectionSwitch (StringRef SectionName, unsigned Characteristics,
4141 StringRef COMDATSymName, COFF::COMDATType Type,
4242 Align Alignment);
4343
44- bool ParseDirectiveProc (StringRef, SMLoc);
45- bool ParseDirectiveEndProc (StringRef, SMLoc);
46- bool ParseDirectiveSegment (StringRef, SMLoc);
47- bool ParseDirectiveSegmentEnd (StringRef, SMLoc);
48- bool ParseDirectiveIncludelib (StringRef, SMLoc);
49- bool ParseDirectiveOption (StringRef, SMLoc);
44+ bool parseDirectiveProc (StringRef, SMLoc);
45+ bool parseDirectiveEndProc (StringRef, SMLoc);
46+ bool parseDirectiveSegment (StringRef, SMLoc);
47+ bool parseDirectiveSegmentEnd (StringRef, SMLoc);
48+ bool parseDirectiveIncludelib (StringRef, SMLoc);
49+ bool parseDirectiveOption (StringRef, SMLoc);
5050
51- bool ParseDirectiveAlias (StringRef, SMLoc);
51+ bool parseDirectiveAlias (StringRef, SMLoc);
5252
53- bool ParseSEHDirectiveAllocStack (StringRef, SMLoc);
54- bool ParseSEHDirectiveEndProlog (StringRef, SMLoc);
53+ bool parseSEHDirectiveAllocStack (StringRef, SMLoc);
54+ bool parseSEHDirectiveEndProlog (StringRef, SMLoc);
5555
5656 bool IgnoreDirective (StringRef, SMLoc) {
5757 while (!getLexer ().is (AsmToken::EndOfStatement)) {
@@ -65,9 +65,9 @@ class COFFMasmParser : public MCAsmParserExtension {
6565 MCAsmParserExtension::Initialize (Parser);
6666
6767 // x64 directives
68- addDirectiveHandler<&COFFMasmParser::ParseSEHDirectiveAllocStack >(
68+ addDirectiveHandler<&COFFMasmParser::parseSEHDirectiveAllocStack >(
6969 " .allocstack" );
70- addDirectiveHandler<&COFFMasmParser::ParseSEHDirectiveEndProlog >(
70+ addDirectiveHandler<&COFFMasmParser::parseSEHDirectiveEndProlog >(
7171 " .endprolog" );
7272
7373 // Code label directives
@@ -115,20 +115,20 @@ class COFFMasmParser : public MCAsmParserExtension {
115115 // goto
116116
117117 // Miscellaneous directives
118- addDirectiveHandler<&COFFMasmParser::ParseDirectiveAlias >(" alias" );
118+ addDirectiveHandler<&COFFMasmParser::parseDirectiveAlias >(" alias" );
119119 // assume
120120 // .fpo
121- addDirectiveHandler<&COFFMasmParser::ParseDirectiveIncludelib >(
121+ addDirectiveHandler<&COFFMasmParser::parseDirectiveIncludelib >(
122122 " includelib" );
123- addDirectiveHandler<&COFFMasmParser::ParseDirectiveOption >(" option" );
123+ addDirectiveHandler<&COFFMasmParser::parseDirectiveOption >(" option" );
124124 // popcontext
125125 // pushcontext
126126 // .safeseh
127127
128128 // Procedure directives
129- addDirectiveHandler<&COFFMasmParser::ParseDirectiveEndProc >(" endp" );
129+ addDirectiveHandler<&COFFMasmParser::parseDirectiveEndProc >(" endp" );
130130 // invoke (32-bit only)
131- addDirectiveHandler<&COFFMasmParser::ParseDirectiveProc >(" proc" );
131+ addDirectiveHandler<&COFFMasmParser::parseDirectiveProc >(" proc" );
132132 // proto
133133
134134 // Processor directives; all ignored
@@ -153,17 +153,17 @@ class COFFMasmParser : public MCAsmParserExtension {
153153 // .alpha (32-bit only, order segments alphabetically)
154154 // .dosseg (32-bit only, order segments in DOS convention)
155155 // .seq (32-bit only, order segments sequentially)
156- addDirectiveHandler<&COFFMasmParser::ParseDirectiveSegmentEnd >(" ends" );
156+ addDirectiveHandler<&COFFMasmParser::parseDirectiveSegmentEnd >(" ends" );
157157 // group (32-bit only)
158- addDirectiveHandler<&COFFMasmParser::ParseDirectiveSegment >(" segment" );
158+ addDirectiveHandler<&COFFMasmParser::parseDirectiveSegment >(" segment" );
159159
160160 // Simplified segment directives
161- addDirectiveHandler<&COFFMasmParser::ParseSectionDirectiveCode >(" .code" );
161+ addDirectiveHandler<&COFFMasmParser::parseSectionDirectiveCode >(" .code" );
162162 // .const
163+ addDirectiveHandler<&COFFMasmParser::parseSectionDirectiveInitializedData>(
164+ " .data" );
163165 addDirectiveHandler<
164- &COFFMasmParser::ParseSectionDirectiveInitializedData>(" .data" );
165- addDirectiveHandler<
166- &COFFMasmParser::ParseSectionDirectiveUninitializedData>(" .data?" );
166+ &COFFMasmParser::parseSectionDirectiveUninitializedData>(" .data?" );
167167 // .exit
168168 // .fardata
169169 // .fardata?
@@ -182,20 +182,20 @@ class COFFMasmParser : public MCAsmParserExtension {
182182 // typedef
183183 }
184184
185- bool ParseSectionDirectiveCode (StringRef, SMLoc) {
186- return ParseSectionSwitch (" .text" , COFF::IMAGE_SCN_CNT_CODE |
185+ bool parseSectionDirectiveCode (StringRef, SMLoc) {
186+ return parseSectionSwitch (" .text" , COFF::IMAGE_SCN_CNT_CODE |
187187 COFF::IMAGE_SCN_MEM_EXECUTE |
188188 COFF::IMAGE_SCN_MEM_READ);
189189 }
190190
191- bool ParseSectionDirectiveInitializedData (StringRef, SMLoc) {
192- return ParseSectionSwitch (" .data" , COFF::IMAGE_SCN_CNT_INITIALIZED_DATA |
191+ bool parseSectionDirectiveInitializedData (StringRef, SMLoc) {
192+ return parseSectionSwitch (" .data" , COFF::IMAGE_SCN_CNT_INITIALIZED_DATA |
193193 COFF::IMAGE_SCN_MEM_READ |
194194 COFF::IMAGE_SCN_MEM_WRITE);
195195 }
196196
197- bool ParseSectionDirectiveUninitializedData (StringRef, SMLoc) {
198- return ParseSectionSwitch (" .bss" , COFF::IMAGE_SCN_CNT_UNINITIALIZED_DATA |
197+ bool parseSectionDirectiveUninitializedData (StringRef, SMLoc) {
198+ return parseSectionSwitch (" .bss" , COFF::IMAGE_SCN_CNT_UNINITIALIZED_DATA |
199199 COFF::IMAGE_SCN_MEM_READ |
200200 COFF::IMAGE_SCN_MEM_WRITE);
201201 }
@@ -210,13 +210,13 @@ class COFFMasmParser : public MCAsmParserExtension {
210210
211211} // end anonymous namespace.
212212
213- bool COFFMasmParser::ParseSectionSwitch (StringRef SectionName,
213+ bool COFFMasmParser::parseSectionSwitch (StringRef SectionName,
214214 unsigned Characteristics) {
215- return ParseSectionSwitch (SectionName, Characteristics, " " ,
215+ return parseSectionSwitch (SectionName, Characteristics, " " ,
216216 (COFF::COMDATType)0 , Align (16 ));
217217}
218218
219- bool COFFMasmParser::ParseSectionSwitch (StringRef SectionName,
219+ bool COFFMasmParser::parseSectionSwitch (StringRef SectionName,
220220 unsigned Characteristics,
221221 StringRef COMDATSymName,
222222 COFF::COMDATType Type,
@@ -233,7 +233,7 @@ bool COFFMasmParser::ParseSectionSwitch(StringRef SectionName,
233233 return false ;
234234}
235235
236- bool COFFMasmParser::ParseDirectiveSegment (StringRef Directive, SMLoc Loc) {
236+ bool COFFMasmParser::parseDirectiveSegment (StringRef Directive, SMLoc Loc) {
237237 StringRef SegmentName;
238238 if (!getLexer ().is (AsmToken::Identifier))
239239 return TokError (" expected identifier in directive" );
@@ -367,9 +367,9 @@ bool COFFMasmParser::ParseDirectiveSegment(StringRef Directive, SMLoc Loc) {
367367 return false ;
368368}
369369
370- // / ParseDirectiveSegmentEnd
370+ // / parseDirectiveSegmentEnd
371371// / ::= identifier "ends"
372- bool COFFMasmParser::ParseDirectiveSegmentEnd (StringRef Directive, SMLoc Loc) {
372+ bool COFFMasmParser::parseDirectiveSegmentEnd (StringRef Directive, SMLoc Loc) {
373373 StringRef SegmentName;
374374 if (!getLexer ().is (AsmToken::Identifier))
375375 return TokError (" expected identifier in directive" );
@@ -380,9 +380,9 @@ bool COFFMasmParser::ParseDirectiveSegmentEnd(StringRef Directive, SMLoc Loc) {
380380 return false ;
381381}
382382
383- // / ParseDirectiveIncludelib
383+ // / parseDirectiveIncludelib
384384// / ::= "includelib" identifier
385- bool COFFMasmParser::ParseDirectiveIncludelib (StringRef Directive, SMLoc Loc) {
385+ bool COFFMasmParser::parseDirectiveIncludelib (StringRef Directive, SMLoc Loc) {
386386 StringRef Lib;
387387 if (getParser ().parseIdentifier (Lib))
388388 return TokError (" expected identifier in includelib directive" );
@@ -398,9 +398,9 @@ bool COFFMasmParser::ParseDirectiveIncludelib(StringRef Directive, SMLoc Loc) {
398398 return false ;
399399}
400400
401- // / ParseDirectiveOption
401+ // / parseDirectiveOption
402402// / ::= "option" option-list
403- bool COFFMasmParser::ParseDirectiveOption (StringRef Directive, SMLoc Loc) {
403+ bool COFFMasmParser::parseDirectiveOption (StringRef Directive, SMLoc Loc) {
404404 auto parseOption = [&]() -> bool {
405405 StringRef Option;
406406 if (getParser ().parseIdentifier (Option))
@@ -435,12 +435,12 @@ bool COFFMasmParser::ParseDirectiveOption(StringRef Directive, SMLoc Loc) {
435435 return false ;
436436}
437437
438- // / ParseDirectiveProc
438+ // / parseDirectiveProc
439439// / TODO(epastor): Implement parameters and other attributes.
440440// / ::= label "proc" [[distance]]
441441// / statements
442442// / label "endproc"
443- bool COFFMasmParser::ParseDirectiveProc (StringRef Directive, SMLoc Loc) {
443+ bool COFFMasmParser::parseDirectiveProc (StringRef Directive, SMLoc Loc) {
444444 StringRef Label;
445445 if (getParser ().parseIdentifier (Label))
446446 return Error (Loc, " expected identifier for procedure" );
@@ -476,7 +476,7 @@ bool COFFMasmParser::ParseDirectiveProc(StringRef Directive, SMLoc Loc) {
476476 CurrentProceduresFramed.push_back (Framed);
477477 return false ;
478478}
479- bool COFFMasmParser::ParseDirectiveEndProc (StringRef Directive, SMLoc Loc) {
479+ bool COFFMasmParser::parseDirectiveEndProc (StringRef Directive, SMLoc Loc) {
480480 StringRef Label;
481481 SMLoc LabelLoc = getTok ().getLoc ();
482482 if (getParser ().parseIdentifier (Label))
@@ -496,7 +496,7 @@ bool COFFMasmParser::ParseDirectiveEndProc(StringRef Directive, SMLoc Loc) {
496496 return false ;
497497}
498498
499- bool COFFMasmParser::ParseDirectiveAlias (StringRef Directive, SMLoc Loc) {
499+ bool COFFMasmParser::parseDirectiveAlias (StringRef Directive, SMLoc Loc) {
500500 std::string AliasName, ActualName;
501501 if (getTok ().isNot (AsmToken::Less) ||
502502 getParser ().parseAngleBracketString (AliasName))
@@ -515,7 +515,7 @@ bool COFFMasmParser::ParseDirectiveAlias(StringRef Directive, SMLoc Loc) {
515515 return false ;
516516}
517517
518- bool COFFMasmParser::ParseSEHDirectiveAllocStack (StringRef Directive,
518+ bool COFFMasmParser::parseSEHDirectiveAllocStack (StringRef Directive,
519519 SMLoc Loc) {
520520 int64_t Size;
521521 SMLoc SizeLoc = getTok ().getLoc ();
@@ -527,7 +527,7 @@ bool COFFMasmParser::ParseSEHDirectiveAllocStack(StringRef Directive,
527527 return false ;
528528}
529529
530- bool COFFMasmParser::ParseSEHDirectiveEndProlog (StringRef Directive,
530+ bool COFFMasmParser::parseSEHDirectiveEndProlog (StringRef Directive,
531531 SMLoc Loc) {
532532 getStreamer ().emitWinCFIEndProlog (Loc);
533533 return false ;
0 commit comments