Method present but the compiler fails to detect it

I have a fraction library. There are methods “to” and “reduce” defined but the compiler on forc test fails to detect them. The errors are something like: \

202 | 
203 | 		};
204 | 		let fr = Fraction::multiply(f1, f3);
    |                    ^^^^^^^^ No method named "multiply" found for type "Fraction".
205 | 		
206 | 		fr

   --> /home/ritik/hello_sway/fraction_sway/src/lib.sw:216:23
214 | 
215 | fn test_create_fraction() {
216 |     let f = Fraction::to(true, 7, 10);
    |                       ^^ No method named "to" found for type "Fraction".
217 | 	assert(f.num == 7);
218 | 	assert (f.den == 10);

This is surprising considering I have done exactly the same thing while building the Signed Int library, but nothing went wrong there. However here, I just get such errors and I don’t get why.

Fraction Library: htt ps://github .c om/harshnambiar/fraction_sway (have to share the piecewise link because some genius thought it would be a good idea to prevent links from being shared on the forum)

PS: perchance, is Fraction a keyword already taken up by the compiler?

Hi there!
I’ve escalated this issue with the sway team, and I’ll comeback once I have something useful.

Anyhow, to avoid spam it is really genius to prevent links.
Sadly, there’s no way to prevent such a rude tone.

I kindly invite you to be more kind and friendly.
We are people just like you, and we can get our feelings hurt too :crying_cat_face:

Hi there!

We do have a fraction lib
Our team forked, built and ran the repo with no issues.

Is the issue solved for you?