Skip to content
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

release-0.66 (closed) #815

Closed
wants to merge 135 commits into from
Closed

release-0.66 (closed) #815

wants to merge 135 commits into from

Conversation

TwitchBronBron
Copy link
Member

Pull request for v0.66.0, which includes some breaking changes.

  • new type tracking improvements, but comes with some breaking changes.

TwitchBronBron and others added 29 commits June 5, 2023 07:54
* Add abstract TypeExpression class

* Convert type tokens to TypeExpressions (#785)

* Convert type tokens to TypeExpressions

* Fixed all tests

* Rebased and fixed any other merge issues

* Further work on SymbolTypeFlags

* Lint fixes

* Fixed issue with using enums as variables

* Uses complete TypeName as Custom type for TypeExpression.getType()

* Removed commented out code, fixed tests

* Fixes from PR review

* Fixed lint issues

---------

Co-authored-by: Mark Pearce <mark.pearce@redspace.com>

* Removes Parsetime Static Type Setting (#791)

* Refactors statically set type to use a function

* Lint fixes

* Removed symbolTable getter from function scope - not used

* Adds ReferenceType (#792)

* Added ReferenceType and some tests

* Added scope linking for hovers

* Removed catch in try/finally in hoverprocessor

* Reverted typo

* Removed commented out code

* Changed to using Proxy, fixed circular references

* Fixed lint, added proper isReferencetype reflection

* Added members to `BscType`, and adds ReferenceType (future lookups) (#794)

* Large update to move BscType to a class and add ReferenceTypes

* Fixes validation errors when calling a dynamicType like a function

* Correctly resolves return types after a function call.

* Removed some commented out or dead code

* Fixed build errors

* BscType.symbolTable -> memberTable, PropertyReferenceType->TypePropertyReferenceType

* Fixed test that should fail

* Fix enum transpile crash

* Refactored `getType` to correctly use `SymbolTypeFlags` (#798)

* Fixed issues with namespaces and invalid things being used as types

* Removed unneeded method

* Ran npm install with latest code

* Removed commented and vestigal code, and added TODOs

* Removed additional commented code

* ClassType and InterfaceType refactor and Inheritance (#800)

* Changed CustomType to ClassType

* Adds BscType.equals(), and ClassType tests for inheritance

* Fixes issue when looking for members of classes with supertypes that were originally ReferenceTypes

* Rerfactor of InterfaceStatement and InetrfaceType work more similar to Classes

* Added tests, changed parentClass/Interface to use TypeExpression

* Fixes issue when classes and namespaces extend from a namespaced parent

* Changes from code review

* Type chain refactor (#802)

* Changed getType() methods to use an options parameter

* Refactors getType() to add opttions, and can find all the types in a chain of types

* Fixed lint errors

* Updated Tests

* Update src/interfaces.ts

Co-authored-by: Bronley Plumb <bronley@gmail.com>

* name change

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>

* Adds Union types (#803)

* initial commit

* Adds UnionType and associated tests

* Added helper functions to get the most general type from a list of types, including Union types

* Started working on Uniontype.membersTypes

* Started working on Uniontype.membersTypes

* Refactor of types to use  instead of

* Fixed lint errors

* Reverted benchmark package changes

* Removes `NamespacedVariableNamedExpressions` (#801)

* Removes NamespacedVariabledNamedExpressions

* Fixed rest of tests

* Fixes ignored parameter value in Parser.identifyingExpression

* UnionType Improvements (#806)

* Reworked type uniqness checking

* Changed logic of InterfaceType.isEqual

* Able to get member types from a UnionType

* Fixed lint errors

* Starting to add UnionExpression and parsing

* Added pipe token

* Added test for if inner type does not include member in UnionType.getMmeberTypes

* Updated UnionExpression transpile logic

* Re-added whitespace

* removed pipe in favor of 'or' for declaring/displaying union types

* Fix lint/build issues

* TypeExpressions more narrowly look for what they can accept

* Whitespace and typo fixes

* Adds unionType validation tests and allows uniontypes innertypes to be late defined

* fixed lint error

* Fixes issue with ReferenceTypes not displaying a full name

* Fix self references in unions (#808)

* Fixes issue with self-referencing symbols in unions

* Fixed lint error

* Type performance improvements (#811)

* Fixes issue with self-referencing symbols in unions

* Fixed lint error

* Starting performance benchmarking

* Starting performance benchmarking

* getType -> ZgetType()

* Reverse getType removal

* Removes double validation in ScopeValidator

* Trying out type caching

* Some benchmark thing

* Removes TypeCache

* Made the in typeExpression function more robust

* Removed unneeded code

* removed bad imports

* Fixes issue with potential crash when checking types

* Adds `enableTypeValidation` flag and documentation (#812)

* Added bsConfig option for enhancedTypingValidation

* Reverted any benchmark changes

* Added docs for 'enhancedTypingValidation' option

* Adds documentation

* In an effort to increase non-enhancedtypeValidation, old methods were re-added to short circuit getType() calls

* Changed flag to enableTypeValidation

* Fixed docs

* Fixed readme formatting

* Fixes from PR review

* Adds SymbolTable.getSymbolType() to wrap caching and ReferenceType creation (#813)

* Adds SymbolTable.getSymbolType() to wrap caching and ReferenceType creation

* Removed commented out code

* Add SymbolTable exports for plugins, etc

* Added exports from ./types

* Adds Type Casting  (#814)

* Adds TypeCastExpression

* Adds TypeCast expression

* fix lint issue

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>

---------

Co-authored-by: Mark Pearce <mark.pearce@redspace.com>
Co-authored-by: Mark Pearce <markwpearce@gmail.com>
* Adds .kind prop to AstNode.
Converts reflection methods to check `kind` which is faster.

* Move .kind props after constructor

* Add BscType .kind, and convert all .kind to strings since it's as fast as ints.
* Refactor XML AST

* Add findLastIndex util function.

* Refactor names of certain nodes

* fix some names

* Rename other elements

* Remove benchmarking log
* Rename SymbolTypeFlags to SymbolTypeFlag

* Remove deprecated functionality
* Rename SymbolTypeFlags to SymbolTypeFlag

* Remove deprecated functionality

* Fix range for missing prop diagnostic
* Updated some references to enableTypeValidation

* Fixes issue with namespace declaration order
Co-authored-by: Bronley Plumb <bronley@gmail.com>
* Performance fixes

* Lift `isUsedAsType` to cached expressionInfo obj

* Slightly more aggressive symbol type caching

* Cache speed boost

* Potentially solved Scope Linking  slow down (#840)

* Potentially solved Scope Linking  slow down

* Favor focused parent lookup instead of parse-time link

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>

* Make CacheVerifier more stable

* fix cross-platform benchmark bug

* Disable execSync logging

* Add specific configuration options for benchmarks at the command line (#841)

Co-authored-by: Bronley Plumb <bronley@gmail.com>

* Added package.json back

* Small optimization during symbol table linking

* Better symbol table type retrieval - uses parent and sibling caches (#842)

* Better use of cache for getting symbol types

* Adds space after function

* Prevent leaking sibling tables

* Add more benchmark padding (just cuz)

* Revert `getSymbolTypeRecursive`

* Better return type for `getScopeByName`

* Optimize buildNamespaceLookup and some string stuff

---------

Co-authored-by: Mark Pearce <markwpearce@gmail.com>
Co-authored-by: Mark Pearce <mark.pearce@redspace.com>
* Removed enableTypeValidation option

* reverted benchmarks change
* BinaryExpression returns runtime type of lhs and rhs

* Added symbolTable type check for binary expressions

* Added unary expression getType()

* Deal with compound assignments as well

* White space change

* Added pne more test

* More tests

* Added function call validation (#839)

* Refactor of hover processing, using SymbolTables and enableTypeValidation (#828)

* Refactor of hover processing, using SymbolTables and enableTypeValidation

* build fix

* Uses SymbolTable and TypeChains for hover details

* Build/lint fixes

* Fix failing tests (caused by having wrong types!)

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
* Allow `as object` types to be used almost everywhere like dynamic

* Fix tsc warning
georgejecook and others added 5 commits December 21, 2023 12:14
* fix that was needed to prevent crashing

* adds unit test that demonstrates crash

* Fixes issue with native interfaces using roSgNode as a param type

---------

Co-authored-by: Mark Pearce <mark.pearce@redspace.com>
* Added diagnostics for writing to unknown or unaccessible members of classes

* Fixes build

* Fixed namespace issues

* Fixes issues with provided/required symbols

* Revert unneccessary change
TwitchBronBron and others added 9 commits January 10, 2024 07:02
* Adds true, false, invalid to completions and ensure function params are included

* Code completion only shows accessible class members

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
* Updates the member types for XML fields

* Fixed tests
* Add test

* Fixes issue with namespaced callables and name collisions

---------

Co-authored-by: Mark Pearce <mark.pearce@redspace.com>
Co-authored-by: Bronley Plumb <bronley@gmail.com>
* Assume types that are members of other types are equal if their names are the same

* Adds tests and fixes for recursive types in arrays

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
* WIP

* Work in Progrss - test failures in BrsFileSemanticTokensProcessor and  CodeActionsProcessor

* Fixed issues with Code action and semantic tokens

* Do one walk for all CachedLookups

* Fix lint

* Made BrsFile.cachedLookups private

* fix build error

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
@TwitchBronBron TwitchBronBron changed the title release v0.66.0 v1.0.0 Jan 24, 2024
TwitchBronBron and others added 9 commits January 25, 2024 11:46
#1043)

* Changed adding invalid as arg to empty callfunc invocations by default

* Update src/BsConfig.ts

Co-authored-by: Bronley Plumb <bronley@gmail.com>

* Update bsconfig.schema.json

Co-authored-by: Bronley Plumb <bronley@gmail.com>

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
* Work in progresss to standardize AST Node constructors

* updated Print, Goto, Increment, Dim, etc

* Label, stop, end, for, for each done

* Working on dottedGet, varaibles, indexSet, dottedSet

* Fixed broken tests

* chnaged namespace statement

* import statement

* interface statement

* Try catch blocks changed

* Enums done

* Const statement

* All Statements done

* BinaryExpressions

* Call and Callfunc

* Func expressions updated

* FunctionParameters done

* XMLAttributeExpression

* IndexedGetExpressions done

* Grouping Expresisons done

* Template strings done

* AA members WIP

* fix tests

* AA literals done

* Annotations, dawg

* Ternary done

* All Statements and Expressions updated

* Removed a bunch of 'Token' suffixes on expression and statement constructor options

* SG AST constructor changes

* Revert SG ast changes

* remove keyword suffix in ClassStatement.tokens

* Updated comment with potential todo for optimization

---------

Co-authored-by: Bronley Plumb <bronley@gmail.com>
@TwitchBronBron TwitchBronBron changed the title v1.0.0 release-0.66 (closed) Feb 1, 2024
@TwitchBronBron
Copy link
Member Author

TwitchBronBron commented Feb 1, 2024

Closing this branch in favor of the new v1.0.0 branch and PR (#1056)

@TwitchBronBron TwitchBronBron deleted the release-0.66.0 branch February 1, 2024 18:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants