Hi all, We started to update the ballerina atom plugin using the updated language files[1]. Using antlr4 we generated the token files [2] for the lexer and parser files. When the plugin is updated with the newly generated files, we get the following error from atom editor, when loading a sample ballerina file. When debugged, the error was thrown from the atom editor when the generated *BallerinaLexer.js *file is loaded to the editor run time. In the previous atom plugin we have generated the token files using a single *Ballerina.G4* but now we have used two different files named, *BallerinaLexer.G4 *and *BallerinaParser.G4. *We have compared the new and old *BallerinaLexer.js *file and the new file contains lot of changes. Any idea on this issue?
[Enter steps to reproduce:] 1. ... 2. ... **Atom**: 1.21.2 x64 **Electron**: 1.6.15 **OS**: Microsoft Windows 10 Pro **Thrown From**: [language-ballerina]( https://github.com/ballerinalang/plugin-atom) package 0.8.8 ### Stack Trace Failed to activate the language-ballerina package ``` At Unexpected identifier SyntaxError: Unexpected identifier at Module.get_Module._compile (~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:94:52) at Object.value [as .js] (~/AppData/Local/atom/app-1.21.2/resources/app/src/compile-cache.js:239:29) at Module.load (module.js:488:32) at tryModuleLoad (module.js:447:12) at Function.Module._load (module.js:439:3) at Module.require (/app.asar/static/index.js:47:45) at require (~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:66:33) at /packages/language-ballerina/lib/language-ballerina.js:7:22) at /packages/language-ballerina/lib/language-ballerina.js:155:39) at Module.get_Module._compile (~/AppData/Local/atom/app-1.21.2/resources/app/src/native-compile-cache.js:106:36) at Object.value [as .js] (~/AppData/Local/atom/app-1.21.2/resources/app/src/compile-cache.js:239:29) at Module.load (module.js:488:32) at tryModuleLoad (module.js:447:12) at Function.Module._load (module.js:439:3) at Module.require (/app.asar/static/index.js:47:45) at require (internal/module.js:20:19) at customRequire (~/AppData/Local/atom/app-1.21.2/resources/app/static/<embedded>:96:26) at Package.module.exports.Package.requireMainModule (~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:903:35) at Package.module.exports.Package.activateNow (~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:242:22) at ~/AppData/Local/atom/app-1.21.2/resources/app/src/package.js:1030:34 at Function.module.exports.Emitter.simpleDispatch (~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:25:20) at Emitter.module.exports.Emitter.emit (~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:141:34) at PackageManager.triggerActivationHook (~/AppData/Local/atom/app-1.21.2/resources/app/src/package-manager.js:727:40) at Workspace.handleGrammarUsed (~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:1400:40) at TextEditor.module.exports.TextEditor.observeGrammar (~/AppData/Local/atom/app-1.21.2/resources/app/src/text-editor.js:708:13) at ~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:579:202 at ~/AppData/Local/atom/app-1.21.2/resources/app/src/workspace.js:584:19 at Function.module.exports.Emitter.simpleDispatch (~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:25:20) at Emitter.module.exports.Emitter.emit (~/AppData/Local/atom/app-1.21.2/resources/app/node_modules/event-kit/lib/emitter.js:141:34) at PaneContainer.didAddPaneItem (~/AppData/Local/atom/app-1.21.2/resources/app/src/pane-container.js:270:24) ``` ### Commands ``` ``` ### Non-Core Packages ``` language-ballerina 0.8.8 ``` [1] - https://github.com/ballerinalang/ballerina/tree/master/docs/grammar [2] - https://drive.google.com/drive/folders/1pAwP2MwZJ4IDRnY8MyAIP-zawSI9ZQoc?usp=sharing -- *Thanks and Best Regards,* Imesh Ashandimal Chandrasiri *Software Engineer* WSO2, Inc. lean . enterprise . middleware *E:* [email protected] | *P:* 0716519187 Disclaimer: This communication may contain privileged or other confidential information and is intended exclusively for the addressee/s. If you are not the intended recipient/s, or believe that you may have received this communication in error, please reply to the sender indicating that fact and delete the copy you received and in addition, you should not print, copy, retransmit, disseminate, or otherwise use the information contained in this communication. Internet communications cannot be guaranteed to be timely, secure, error or virus-free. The sender does not accept liability for any errors or omissions.
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
