[Prev][Next][Index][Thread]

ncurses and Gwydion Dylan



In searching for a compilable language to replace C++, I've recently
discovered Dylan, and really like what I see. So, I grabbed Gwydion
Dylan and began trying to learn.

Most of my programs are text-based, so I'm trying to use melange to
generate a ncurses wrapper. My dcurses.intr file looks as follows:

module: dcurses
synopsis: An interface to curses

define library dcurses
  use dylan;
  use streams;
end library dcurses;

define moduled dcurses
  use dylan;
  use extensions;
  use extern;
  use streams;
  use standard-io;
end module dcurses;

define interface
#include "/usr/include/ncurses.h"
end interface;

When I run melange on this, I receive the following errors:

melange: <SCREEN> has multiple definitions
No applicable methods in call of {GF c-accessor} when given arguments:
  #[{<predefined-type-declaration> instance}, "index * 0", "ptr", "<_IO-lock-t>"]
Abort

I conceptually understand the multiple definitions line, though I
don't see what's causing it. AFAIK, ncurses.h declares a screen
struct, and then typedefs SCREEN to that? Is Dylan case insensitive?

Also, I'm not very clear on the meanings of the last two errors. Can
anyone please give me a few pointers?

Thanks.



Follow-Ups: