Welcome to Web-News
A Web-based News Reader
Subject Unexpected restriction of file names ???
From Georg Wrede <georg.wrede@nospam.org>
Date Wed, 09 Nov 2005 10:35:37 +0200
Newsgroups digitalmars.D

I have the following file, called foo-bar.d:

void main(){}

Trying to compile this gives the following error message:

$dmd foo-bar.d
foo-bar.d: module foo-bar has non-identifier characters in filename, use
module declaration instead


I fear this is on purpose, so I didn't post on Bugs.
But this is unexpected behavior from a compiler.

--------------------

Doing my homework while writing this, I found out that the following
change does away with the problem:

module foobar;
void main(){}


Now "dmd foo-bar.d" compiles ok.

--------------------

This should at least get more prominent in the docs, and if there ever
will be a faq, this should be there too.

Recent messages in this thread
 
-# Unexpected restriction of file names ??? (Current message) Georg Wrede 09-Nov-2005 03:35 am
.|# Re: Unexpected restriction of file names ??? Jarrett Billingsley 09-Nov-2005 08:35 am
.-# Re: Unexpected restriction of file names ??? J C Calvarese 09-Nov-2005 08:42 am
..\# Re: Unexpected restriction of file names ??? Georg Wrede 09-Nov-2005 07:52 pm