-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: Cannot read property 'flags' of undefined #84
Comments
@frankebersoll The current symbol flag value is 134217732. This is a combination of SymbolFlags.Prototype + SymbolFlags.Property. The symbol dump indicates that you have something like
I realize that "prototype" is a reserved word and thus cannot be shortened. I will review how reserved words are treated in TsProject. I will need to add a test for this usage and investigate. Perhaps you can provide a code snippet from your project for this purpose. I will resolve this issue early next week. |
Hey Todd, you can use this commit to reproduce the issue: exceptionless/Exceptionless.JavaScript@113155c Cheers and have a nice weekend! |
@frankebersoll I don't use git command line, so I am not sure how to download the source you are referring to above. I tried downloading the features/build branch, but I cannot get it to compile without error. Please let me know what to download to reproduce this issue. Thanks. |
@frankebersoll I've been able to recreate this issue by downloading exceptionless.javascript release 1.3.2 and modifying it slightly. |
@frankebersoll This is an interesting issue. It is not straight forward! |
@frankebersoll I've opened an issue with the TypeScript project microsoft/TypeScript#8024 I need to resolve the TypeScript issue before I can complete fixing your issue. |
@frankebersoll @niemyjski I believe the solution to this issue can be handled by simply checking for a null valueDeclaration. However, as I thought, there are issue(s) that (may) result from this. TypeScript 1.8.9 does not resolve the Type for |
@frankebersoll @niemyjski I've written some experimental code to resolve the Type for |
@ToddThomson I don't think we are in any big hurry but we are looking to switch from uglify to the new stuff soon. |
I don't say this enough but I really appreciate all the work you do! |
@niemyjski Thanks! |
This issue has been addressed in release 1.2.1. Thank-you for your input! |
Awesome!! |
Great stuff, thank you so much! |
@frankebersoll @niemyjski You're welcome. |
It looks like we are still hitting this issue. I'll work on getting more information. |
@ToddThomson do you know if any progress has been made on this, it looks like it's the same exact issue that we ran into before (Just working on upgrading us to latest typescript https://github.com/exceptionless/Exceptionless.JavaScript/tree/feature/latest-ts)
Seems to only happen when were running |
I think this has something to do with how we export functions in our tests:
The passed in type to typescript.getBaseTypes(type) has an intrinsicName of unknown. and the symbol object is just the function name we export in the previous stack frame |
Kinda getting the feeling that it's expecting my functions to be exported from a class, and they are not (they are just test scripts) |
When building our project with minification enabled, we get this:
Looks like "A property has a value declaration" isn't true in every case, but I don't know enough about the AST to understand what's going on here.
The current symbol looks like this:
The text was updated successfully, but these errors were encountered: