- Code: Select all
namespace ESutils_
class Program
def main
print 'hello'
class MyRandom inherits Random
cue init
base.init
enum Coin
heads, tails
def next(lowValue as int, highValue as int) as int #fix next from random class,
assert lowValue <= highValue
assert highValue + 1 <= int.maxValue
return base.next(lowValue, highValue + 1)
def next(lowPitchName as Coin, highPitchName as Coin) as int #fix next from random class,
lowValue = 1 #lowPitchName to int
highValue = 2 #highPitchName to int
assert lowValue <= highValue
assert highValue + 1 <= int.maxValue
return base.next(lowValue, highValue + 1)
error msg:
C:\Users\Paul\Desktop\foldername>cobra esutils
error: COBRA INTERNAL ERROR / FallThroughException / info=MemberOverload-sh(9422, name=next, didBindInh=false, didStartBindInt=true, didBindInt=true,
didBindImp=false, token=Token.empty, name=next, isNames=['public'], numMembers=3, parentBox=Class-mi(1525, name=Random, didStartBindInh=true, didBindI
nh=true, didStartBindInt=true, didBindInt=true, didBindImp=false, token=Token.empty, didBindInh=true, isGeneric=false, isGenericDef=false, needsConstr
uction=false, 1525), 9422)
Compilation failed - 1 error, 0 warnings
Not running due to errors above.
Any comments? If the fault is mine and I'm missing something obvious in my code causing the error, I can't spot it.