[Issue 4563] [module system] Error messages for missing package or missing name

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Oct 24 05:09:14 PDT 2012


http://d.puremagic.com/issues/show_bug.cgi?id=4563



--- Comment #7 from bearophile_hugs at eml.cc 2012-10-24 05:09:04 PDT ---
(In reply to comment #6)

> This is the only test-case left to fix in this Issue (the others seem to be
> fixed).

This is the current situation:

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

// Case#1
import std.bitmanips: bitfields;
void main() {}

test.d(1): Error: module bitmanips is in file 'std\bitmanips.d' which cannot be
read
import path[0] = C:\dmd2\src\phobos\
import path[1] = C:\dmd2\src\druntime\import\
import path[2] = C:\leonardo\d_bugs\
import path[3] = C:\dmd2\windows\bin\..\..\src\phobos
import path[4] = C:\dmd2\windows\bin\..\..\src\druntime\import

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

// Case#2
import std.bitmanip: bitfield;
void main() {}

test.d(1): Error: module std.bitmanip import 'bitfield' not found, did you mean
'template bitfields(T...)'?

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

// Case#3
import std.math: foo;
void main() {}

test.d(1): Error: module std.math import 'foo' not found, did you mean
'function fma'?

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

The Case#1 probably needs a better error message.

The messages in cases #2 and #3 seem acceptable, it's not bad. But they
sub-optimal, in Case#3 this seems better:

test.d(1): Error: name 'foo' not found in module std.math, did you mean
function 'fma'?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list