| define(function (require) { |
| var $ = require('jquery'); |
| var monaco = require('monaco'); |
| var cpp = require('vs/basic-languages/src/cpp'); |
| // We need to create a new definition for cpp so we can remove invalid keywords |
| var cppp = $.extend(true, {}, cpp.language); // deep copy |
| function removeKeyword(keyword) { |
| var index = cppp.keywords.indexOf(keyword); |
| cppp.keywords.splice(index, 1); |
| removeKeyword("interface"); |
| monaco.languages.register({id: 'cppp'}); |
| monaco.languages.setLanguageConfiguration('cppp', cpp.conf); |
| monaco.languages.setMonarchTokensProvider('cppp', definition()); |