Skip to content

Commit e00af06

Browse files
committed
Merge remote-tracking branch 'github/feature/pointer_declaration'
2 parents 7ba95a2 + 454d8cf commit e00af06

File tree

1 file changed

+25
-1
lines changed

1 file changed

+25
-1
lines changed

src/fortran/ofp/XMLPrinter.java

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -783,10 +783,34 @@ public void named_constant_def(Token id) {
783783
contextClose();
784784
}
785785

786+
public void pointer_stmt(Token label, Token keyword, Token eos) {
787+
super.pointer_stmt(label, keyword, eos);
788+
if (!context.getTagName().equals("declaration"))
789+
LOG.warning("pointer_stmt in unexpected context");
790+
setAttribute("type", "pointer");
791+
}
792+
786793
public void pointer_decl_list__begin() {
787794
if (!context.getTagName().equals("declaration"))
788795
contextOpen("declaration");
789-
super.pointer_decl_list__begin();
796+
contextOpen("names");
797+
if (verbosity >= 100)
798+
super.pointer_decl_list__begin();
799+
}
800+
801+
public void pointer_decl_list(int count) {
802+
contextCloseAllInner("names");
803+
if (verbosity >= 100)
804+
super.pointer_decl_list(count);
805+
setAttribute("count", count);
806+
contextClose("names");
807+
}
808+
809+
public void pointer_decl(Token id, boolean hasSpecList) {
810+
contextOpen("name");
811+
super.pointer_decl(id, hasSpecList);
812+
setAttribute("id", id);
813+
contextClose("name");
790814
}
791815

792816
public void save_stmt(Token label, Token keyword, Token eos, boolean hasSavedEntityList) {

0 commit comments

Comments
 (0)