| 26 | using namespace hdlConvertor::hdlAst; |
| 27 | |
| 28 | void VerModuleParser::visitModule_header_common( |
| 29 | sv2017Parser::Module_header_commonContext *ctx, HdlModuleDec &ent) { |
| 30 | // module_header_common: |
| 31 | // ( attribute_instance )* module_keyword ( lifetime )? identifier |
| 32 | // ( package_import_declaration )* ( parameter_port_list )?; |
| 33 | VerAttributeParser::visitAttribute_instance(ctx->attribute_instance()); |
| 34 | auto lt = ctx->lifetime(); |
| 35 | if (lt) { |
| 36 | NotImplementedLogger::print( |
| 37 | "VerModuleParser.visitModule_header_common - lifetime", lt); |
| 38 | } |
| 39 | ent.__doc__ = commentParser.parse(ctx); |
| 40 | ent.name = ctx->identifier()->getText(); |
| 41 | for (auto pid : ctx->package_import_declaration()) { |
| 42 | NotImplementedLogger::print( |
| 43 | "VerModuleParser.visitModule_header_common - package_import_declaration", |
| 44 | pid); |
| 45 | } |
| 46 | auto mppl = ctx->parameter_port_list(); |
| 47 | if (mppl) { |
| 48 | VerParamDefParser pp(this); |
| 49 | pp.visitParameter_port_list(mppl, ent.generics); |
| 50 | } |
| 51 | } |
| 52 | void VerModuleParser::visitModule_declaration( |
| 53 | sv2017Parser::Module_declarationContext *ctx, |
| 54 | vector<unique_ptr<iHdlObj>> &res) { |
nothing calls this directly
no test coverage detected