Broke my Module?

I wrote my own module that contains various structs and methods which act on them. My typical process is to have on the left a script that loads my module and on the right the module source code. I have been using Revise.jl so I don’t have to recompile each time I make a change.

I have no idea what I did, but now when I first start up VSCode and run my script for the first time I see the following error.

WARNING: Method definition (::Type{MyModule.MyMethod})(MyModule.MyMethod, Float64, Float64) in module MyModuleat /PATH/MyModule/src/MyModule.jl:76 overwritten at /PATH/MyModule/src/MyModule.jl:82.
  ** incremental compilation may be fatally broken for this module **

Everything appears to still work though. Still, I’d like to fix it if possible.
Any ideas what I did and how I might fix it?

I seemed to have fixed it. I think this was my problem. I was making changes to my code and basically (on accident) made some outer constructors equivalent to the struct definition. Something like

struct MyStruct

function MyStruct(Stuff1, Stuff2)
    # Some old code here that had been commented out, did some setup that i no longer need. 
    return MyStruct(Stuff1, Stuff2)

Once I removed the function I stopped getting the compilation error.

The error message usually means the function at line 76 has the same type signature as the one at line 82.

And, as you found out, this will occur when you’re developing code by hacking away. I’ve even had it where I have ended up with both functions having the same body too, without noticing!