Changeset 2301 for cobra/trunk/Source/Phases/IdentifyMainPhase.cobra
- Timestamp:
- 03/06/10 03:58:16 (2 years ago)
- Files:
-
- 1 modified
-
cobra/trunk/Source/Phases/IdentifyMainPhase.cobra (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
cobra/trunk/Source/Phases/IdentifyMainPhase.cobra
r2202 r2301 19 19 if c.errors.count > 0, return # otherwise, messes up testify 20 20 21 count = 0 22 for mod in c.modules, if mod inherits CobraModule, count += 1 23 if count == 0, return # probably all sharp modules 24 21 25 typeName = .options.getDefault('main', '') to String 22 26 mainList = MainCollector().collect(c, typeName) 23 27 if mainList.count == 0 24 .recordError('Cannot find a "main" method.') 28 detail = if(typeName.length, ' in [typeName]', '') 29 .recordError('Cannot find a "main" method[detail].') 25 30 return 26 31 if mainList.count > 1



