[m-users.] mmc --make giving strange warnings/errors

Kilian Evang maschinenraum at texttheater.net
Sun Jan 12 08:56:33 AEDT 2014


Hi all,

I've recently started around playing with Mercury and am concerned about
strange warnings/errors I get for some programs when trying to mmc
--make them. I've attached a minimal example (test.m) and the error
output I get (test.err).

In this case, it seems to be the type declaration in the implementation
part that triggers the error. If I remove it or move it to the interface
part, the program compiles quietly.

As far as I can tell, the generation of working executables is not
affected, it's just perplexing and worrying.

My OS/Mercury version:

ke at apis:~/mercury$ uname -a
Linux apis 3.11.0-15-generic #23-Ubuntu SMP Mon Dec 9 18:17:04 UTC 2013
x86_64 x86_64 x86_64 GNU/Linux
ke at apis:~/mercury$ mmc --version
Mercury Compiler, version 13.05.2, configured for x86_64-unknown-linux-gnu
Copyright (C) 1993-2013 The University of Melbourne
ke at apis:~/mercury$

Any ideas what is wrong?

Cheers,
Kilian
-------------- next part --------------
In file included from /home/ke/lib/mercury/inc/mercury_context.h:59:0,
                 from /home/ke/lib/mercury/inc/mercury_heap.h:29,
                 from /home/ke/lib/mercury/inc/mercury_string.h:12,
                 from /home/ke/lib/mercury/inc/mercury_imp.h:51,
                 from Mercury/cs/test.c:24:
  MR_PASTE2(mercury__, label)
            ^
/home/ke/lib/mercury/inc/mercury_goto.h:881:14: note: in definition of macro ?MR_declare_static?
  static void label(void) __asm__("_entry_" MR_STRINGIFY(label))
              ^
/home/ke/lib/mercury/inc/mercury_std.h:268:26: note: in expansion of macro ?MR_PASTE2_2?
 #define MR_PASTE2(a,b)   MR_PASTE2_2(a,b)
                          ^
/home/ke/lib/mercury/inc/mercury_goto.h:30:2: note: in expansion of macro ?MR_PASTE2?
  MR_PASTE2(mercury__, label)
  ^
/home/ke/lib/mercury/inc/mercury_goto.h:1672:20: note: in expansion of macro ?MR_add_prefix?
  MR_declare_static(MR_add_prefix(e));
                    ^
Mercury/cs/test.c:64:1: note: in expansion of macro ?MR_decl_static?
 MR_decl_static(__Unify___test__a_0_0)
 ^
  MR_PASTE2(mercury__, label)
            ^
/home/ke/lib/mercury/inc/mercury_goto.h:881:14: note: in definition of macro ?MR_declare_static?
  static void label(void) __asm__("_entry_" MR_STRINGIFY(label))
              ^
/home/ke/lib/mercury/inc/mercury_std.h:268:26: note: in expansion of macro ?MR_PASTE2_2?
 #define MR_PASTE2(a,b)   MR_PASTE2_2(a,b)
                          ^
/home/ke/lib/mercury/inc/mercury_goto.h:30:2: note: in expansion of macro ?MR_PASTE2?
  MR_PASTE2(mercury__, label)
  ^
/home/ke/lib/mercury/inc/mercury_goto.h:1672:20: note: in expansion of macro ?MR_add_prefix?
  MR_declare_static(MR_add_prefix(e));
                    ^
Mercury/cs/test.c:65:1: note: in expansion of macro ?MR_decl_static?
 MR_decl_static(__Compare___test__a_0_0)
 ^
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test.m
Type: text/x-objcsrc
Size: 187 bytes
Desc: not available
URL: <http://lists.mercurylang.org/archives/users/attachments/20140111/a7709cb5/attachment.bin>


More information about the users mailing list