Closed fuhrmanator closed 3 months ago
can you provide a small model to test ?
This is Moose 10, using the MM at https://github.com/fuhrmanator/FamixTypeScript?tab=readme-ov-file#loading-from-a-playground
simplemodel.typescript.json Transcript.txt
The source file is this TypeScript file (test_src/basicExport.ts)
export const variable1 = "Hello, World!";
This issue maybe needs to be in the FamixTypeScript repo (if it's a MM problem rather than importer problem). I can transfer it there, if needed.
Some points from an initial analysis:
As such, there is a getter but not a setter for #name
I loaded the FamixTypeScript project using the Metacello script in the Readme of this project...
Note: main problem was actually with #start_line
Analysis: It is also derived (no setter, only a getter).
It is computed from the #startPos and the length of the lines in the source file.
To use #startLine: one should use the trait FamixTFileNavigation
instead of FamixTIndexedFileNavigation
.
The former wants startLine/startColumn/endLine/endColumn
If one wants #startLine from FamixTIndexedFileNavigation
, it is derived (computed), providing one has access to the #completeText of the file, itself subject to having a correct #rootFolder.
If you agree with all this, you can close the issue. Tx for helping
Thanks for your help! I agree with these but will leave it open until we make the changes to the MM and importer.
Many, not all, are fixed in #63. Remaining ones are problems with concretizations/genericity.