BBx-Kitchen / bbj-language-server

BBj Language Server
MIT License
6 stars 6 forks source link

How to define project wide USE-Statements ? #83

Open SebastianAdams opened 1 year ago

SebastianAdams commented 1 year ago

Is there a way to add USE-statements on a project level to make them available for all project files, like it is possible to do so in BBj by adding them in the config.bbx ?

See the USE section in the following documentation page for more information about the current behavior: https://documentation.basis.cloud/BASISHelp/WebHelp/sysadmin/config/the_config_bbx_configuration_file_bbj_spec.htm

dhuebner commented 1 year ago

@SebastianAdams We support implicit imported types for some BBj internals. To be honest I don't like the idea having implicit imports in all project files as it will pollute the scope with probably unneeded symbols. This will also make scoping and linking slower. Are you normally change this project wide imported types?

SebastianAdams commented 1 year ago

@dhuebner We don't use them that often as far as I know, but I have a project where this was used, and adding the USE-Statements now would be tedious. Can we agree on adding a flag to support this behavior for the projects where we need it and disable it by default for all other projects ?

hyyan commented 1 year ago

related to https://github.com/BBx-Kitchen/bbj-language-server/issues/24

StephanWald commented 1 year ago

the USE is in the config.bbx Since we have the config.bbx parsing in place, I'd vote for simply planning to support the USE statements in the config.bbx. Maybe they can be "merged" into the program source as "virtual global USE statements"