Ambiguous name error with non-unique domains
Posted: 7 Aug 2021 19:02
I have an add build problem that has come along intermittently over the last few months. I have a large set of simple domains, many of which include the word "none" as one of its members. Example
My project has half a dozen classes, all of which use these domains, so I have them declared in main.cl with "open core, main" included in the .cl and .pro files of each class.
Sometimes(!) not always, after adding new classes I start getting the error
e217 Ambiguous name usage 'none' ('core::none' or 'core::none' or...)
followed by s217 warnings repeating the same error message for each domain with 'none' in it.
The actual error is linked to a specific line of a clause that is using 'none', but I am certain that the variable Effect is declared as a domain with 'none' in it.
I've had this happen a few times now, and solved sometimes by making sure I was opening main in both the cl and pro files, but now I have it again and I definitely have main open in both the cl and pro files. Is there something else that cause it to require all the elements in the domains to be unique? Or am I completely off base as to what is actually causing it?
Code: Select all
domains
%General use domains
flag = yes; no.
valid = valid; notvalid.
updowntype = up; down.
gamephasetype = takethelead; raisetheplan; executetheplan; recount; checkendgame; none.
%domains for characters; weapons and stats
gender = female; male.
effect = poisoned; hypnotized; none.
faction = hero; villain; none.
messagetype = igotthis; helpme; goforit; canthelpnow; none.
Sometimes(!) not always, after adding new classes I start getting the error
e217 Ambiguous name usage 'none' ('core::none' or 'core::none' or...)
followed by s217 warnings repeating the same error message for each domain with 'none' in it.
The actual error is linked to a specific line of a clause that is using 'none', but I am certain that the variable Effect is declared as a domain with 'none' in it.
Code: Select all
elseif ObjectiveVerb = effect and Effect <> none then
I've had this happen a few times now, and solved sometimes by making sure I was opening main in both the cl and pro files, but now I have it again and I definitely have main open in both the cl and pro files. Is there something else that cause it to require all the elements in the domains to be unique? Or am I completely off base as to what is actually causing it?
Code: Select all
class objectiveHandler : objectiveHandler
open core, main, common