Mantis Bug Tracker

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0006410OCamlOCaml generalpublic2014-05-11 07:322014-05-11 10:14
Reporterwhitequark 
Assigned Togarrigue 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version4.02.0+dev 
Summary0006410: Error message for an attempt to use a functor as a module is confusing
DescriptionE.g.:

    module Server(Backend: BACKEND) : sig .. end
    let server = Block.Server.create backend sserver

results in the following error:

    File "lib_test/test_block.ml", line 53, characters 16-35:
    Error: Unbound value Block.Server.create

It would be much better if the error said that Block.Server is a functor, not a structure.
TagsNo tags attached.
Attached Files

- Relationships

-  Notes
(0011424)
garrigue (manager)
2014-05-11 10:14

Fixed in trunk at revision 14790.

module F(X : sig end) = struct let x = 3 end;;
F.x;;
^^^
Error: The module F is a functor, not a structure

- Issue History
Date Modified Username Field Change
2014-05-11 07:32 whitequark New Issue
2014-05-11 10:14 garrigue Note Added: 0011424
2014-05-11 10:14 garrigue Status new => resolved
2014-05-11 10:14 garrigue Fixed in Version => 4.02.0+dev
2014-05-11 10:14 garrigue Resolution open => fixed
2014-05-11 10:14 garrigue Assigned To => garrigue


Copyright © 2000 - 2011 MantisBT Group
Powered by Mantis Bugtracker