<html><head><meta http-equiv="content-type" content="text/html; charset=us-ascii"></head><body style="overflow-wrap: break-word; -webkit-nbsp-mode: space; line-break: after-white-space;">I have a module called `core` in file core.m<div>I have a sub-module called `core.comments` in file core.comments.m</div><div><font face="Andale Mono"><br></font></div><div><div><font face="Andale Mono">:- module core.comments.</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- interface.</font></div><div><font face="Andale Mono">:- import_module io.</font></div><div><span style="font-family: "Andale Mono";">:- import_module fm.</span></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- pred comment_line(opstate::in, opstate::out, dstk::in, dstk::out, </font><span style="font-family: "Andale Mono";">io::di, io::uo) is det.</span></div><div><span style="font-family: "Andale Mono";">:- pred comment_parens(opstate::in, opstate::out, dstk::in, dstk::out,</span><span style="font-family: "Andale Mono";">io::di, io::uo) is det.</span></div><div><br></div><div>and my parent module is defined like this:</div></div><div><br></div><div><div><font face="Andale Mono">:- module core.</font></div><div><font face="Andale Mono">:- interface.</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- import_module bool.</font></div><div><font face="Andale Mono">:- import_module io.</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- import_module fm.</font></div><div><font face="Andale Mono">:- import_module vm.</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- implementation.</font></div><div><font face="Andale Mono">:- import_module list.</font></div><div><font face="Andale Mono">:- import_module string.</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- include_module comments. %% <====</font></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono">:- import_module dstack.</font></div></div><div><div><font face="Andale Mono"><br></font></div></div><div><font face="Andale Mono"><br></font></div><div><font face="Andale Mono"><div>55 core("\\", ccall(yes, comment_line)).</div><div>56 core("(", ccall(yes, comment_parens)).</div></font></div><div><br></div><div>I have compared this to many examples in the Mercury source code and I am sure I have done the same as that, however the compiler remains unconvinced:</div><div><br></div><div><div><font face="Andale Mono">core.m:055: In clause for predicate `core'/2:</font></div><div><font face="Andale Mono">core.m:055: in argument 2 of clause head:</font></div><div><font face="Andale Mono">core.m:055: in argument 2 of functor `ccall/2':</font></div><div><font face="Andale Mono">core.m:055: error: undefined symbol `comment_line'/0.</font></div><div><font face="Andale Mono">core.m:056: In clause for predicate `core'/2:</font></div><div><font face="Andale Mono">core.m:056: in argument 2 of clause head:</font></div><div><font face="Andale Mono">core.m:056: in argument 2 of functor `ccall/2':</font></div><div><font face="Andale Mono">core.m:056: error: undefined symbol `comment_parens'/0.</font></div><div><font face="Andale Mono">** Error making `Mercury/cs/core.c'.</font></div></div><div><br></div><div>It's the first time I've used this feature.</div><div><br></div><div>TIA,</div><div>Sean.</div><div><br></div><div><br></div><div><br></div></body></html>