오병진

Results 47 comments of 오병진

I'll work on it! How do I reproduce this error?

@kdy1 I think it is a failure if the rhs element cannot be assigned to the rhs element. But is there a reason to succeed? https://github.com/dudykr/stc/blob/1f762d8b2becb5a43491d301bf2409615d328112/crates/stc_ts_file_analyzer/src/analyzer/assign/type_el.rs#L1476

We check all the properties Values with different keys are not inspected. Then is rhs not accessible to lhs valid?

[it](https://www.typescriptlang.org/play?noImplicitAny=false&strictNullChecks=false&strictFunctionTypes=false&strictPropertyInitialization=false&strictBindCallApply=false&noImplicitThis=false#code/JYOwLgpgTgZghgYwgAgILIN4ChnLgLmQGcwpQBzAbiwF8tRJZEUAhTHZAI0JLJCtr1w0eEmQBhdrgQ9SFanQYjmyACJTkAE1l8BdLABsIYPMgC8mGniJpqRk53OXryFtThPO1IA)'s faild But we succeed. ![image](https://user-images.githubusercontent.com/64676070/208019211-a8180b6e-3c18-4820-93c8-a649c646f881.png)

Test files are stored in my branch.

this function is not using allow_unknown_type option, and rhs is not unknown. ![image](https://user-images.githubusercontent.com/64676070/208022730-8b8cc01e-1290-4517-a528-1937fa33e6bf.png)

Instead of returning Ok at the end, I returned the error and turned the test around. target of we is successed but, 16 of test file is failed

Of course, but If there is no logical problem and the intent of the function implementer is correct, I think it is a matter of modifying the implementation. Therefore, I...

The logic I think is as follows. Check the body and extension of the interface If both are errors, return the error.

https://github.com/dudykr/stc/blob/1f762d8b2becb5a43491d301bf2409615d328112/crates/stc_ts_file_analyzer/src/analyzer/assign/mod.rs#L1965-L2000